[PATCH] PopplerAttachment.size should be signed The type of PopplerAttachment.size should be signed (i.e. gssize) because poppler uses -1 to indicate that no size was given.

Thomas Viehmann tv at beamnet.de
Sat Jan 17 10:29:15 PST 2009


---
 glib/poppler-attachment.h |    2 +-
 glib/test-poppler-glib.cc |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/glib/poppler-attachment.h b/glib/poppler-attachment.h
index d506167..6e95379 100644
--- a/glib/poppler-attachment.h
+++ b/glib/poppler-attachment.h
@@ -43,7 +43,7 @@ struct _PopplerAttachment
 
   gchar *name;
   gchar *description;
-  gsize size;
+  gssize size;
   GTime mtime;
   GTime ctime;
   GString *checksum;
diff --git a/glib/test-poppler-glib.cc b/glib/test-poppler-glib.cc
index 7f2c1e5..c7f0a9f 100644
--- a/glib/test-poppler-glib.cc
+++ b/glib/test-poppler-glib.cc
@@ -370,7 +370,7 @@ dump_attachment(char* filename, PopplerAttachment* attachment)
   char *strdate;
   g_print ("\t\tname: %s\n", attachment->name);
   g_print ("\t\tdescription: %s\n", attachment->description);
-  g_print ("\t\tsize: %" G_GSIZE_FORMAT "\n", attachment->size);
+  g_print ("\t\tsize: %" G_GSSIZE_FORMAT "\n", attachment->size);
   strdate = poppler_format_date (attachment->ctime);
   if (strdate)
     {
-- 
1.5.6.5


--------------000508090702040409040608--


More information about the poppler mailing list