[poppler] 3 commits - poppler/Annot.cc poppler/Form.cc qt4/src

Pino Toscano pino at kemper.freedesktop.org
Tue Feb 12 02:26:13 PST 2008


 poppler/Annot.cc        |    1 +
 poppler/Form.cc         |    2 ++
 qt4/src/poppler-form.cc |    2 +-
 3 files changed, 4 insertions(+), 1 deletion(-)

New commits:
commit 4e2ba70a88c40fef6775053b1cc5fa30e622cea7
Author: Pino Toscano <pino at kde.org>
Date:   Tue Feb 12 11:25:34 2008 +0100

    Free the Object after you use it.

diff --git a/poppler/Annot.cc b/poppler/Annot.cc
index 7dc8537..9b0b5ce 100644
--- a/poppler/Annot.cc
+++ b/poppler/Annot.cc
@@ -2825,6 +2825,7 @@ void AnnotWidget::generateFieldAppearance() {
     dictObj.initDict(d);
 
     xref->setModifiedObject(&dictObj, ref);
+    dictObj.free();
   }
 
   if (fontDict) {
commit 039545fcd2c12631c7b8aea89c35f36cb387a17a
Author: Pino Toscano <pino at kde.org>
Date:   Tue Feb 12 11:13:27 2008 +0100

    Return the siblings even for checkboxes.

diff --git a/qt4/src/poppler-form.cc b/qt4/src/poppler-form.cc
index c1942ef..f206f69 100644
--- a/qt4/src/poppler-form.cc
+++ b/qt4/src/poppler-form.cc
@@ -183,7 +183,7 @@ void FormFieldButton::setState( bool state )
 QList<int> FormFieldButton::siblings() const
 {
   FormWidgetButton* fwb = static_cast<FormWidgetButton*>(m_formData->fm);
-  if (fwb->getButtonType() != formButtonRadio)
+  if (fwb->getButtonType() == formButtonPush)
     return QList<int>();
 
   QList<int> ret;
commit fe5ee75cdf3e11e314318af12edf9d5bc8986250
Author: Pino Toscano <pino at kde.org>
Date:   Tue Feb 12 11:12:01 2008 +0100

    Initialize correctly; free your memory.

diff --git a/poppler/Form.cc b/poppler/Form.cc
index f356477..4eebbde 100644
--- a/poppler/Form.cc
+++ b/poppler/Form.cc
@@ -172,6 +172,7 @@ FormWidgetButton::FormWidgetButton (XRef *xrefA, Object *aobj, unsigned num, Ref
   onStr = NULL;
   state = gFalse;
   siblingsID = NULL;
+  numSiblingsID = 0;
 }
 
 FormWidgetButton::~FormWidgetButton ()
@@ -275,6 +276,7 @@ void FormWidgetButton::loadDefaults ()
   } else if (obj1.isArray()) { //handle the case where we have multiple choices
     error(-1, "FormWidgetButton:: multiple choice isn't supported yet\n");
   }
+  obj1.free();
 }
 
 GBool FormWidgetButton::getState ()


More information about the poppler mailing list