]> git.sur5r.net Git - glabels/commitdiff
2004-08-14 Jim Evins <evins@snaught.com>
authorJim Evins <evins@snaught.com>
Sun, 15 Aug 2004 01:54:26 +0000 (01:54 +0000)
committerJim Evins <evins@snaught.com>
Sun, 15 Aug 2004 01:54:26 +0000 (01:54 +0000)
* libglabels/xml-paper.c: (gl_xml_paper_parse_paper_node):
* libglabels/xml-template.c: (gl_xml_template_parse_template_node):
* src/xml-label-191.c: (xml191_parse_sheet):
Fixed improper freeing of gettext strings.  Merged from 2.0.1.
* configure.in:
Reconciled libglabels versioning with 2.0.1.

git-svn-id: https://glabels.svn.sourceforge.net/svnroot/glabels/trunk@457 f5e0f49d-192f-0410-a22d-a8d8700d0965

glabels2/ChangeLog
glabels2/configure.in
glabels2/libglabels/xml-paper.c
glabels2/libglabels/xml-template.c
glabels2/src/xml-label-191.c

index ffbb3d34404d2cf76dfc39fd7dd19fffd662119b..4a5842703c9c52c58a10414e5c96c47a2a36c3ec 100644 (file)
@@ -1,3 +1,13 @@
+2004-08-14  Jim Evins  <evins@snaught.com>
+
+       * libglabels/xml-paper.c: (gl_xml_paper_parse_paper_node):
+       * libglabels/xml-template.c: (gl_xml_template_parse_template_node):
+       * src/xml-label-191.c: (xml191_parse_sheet):
+               Fixed improper freeing of gettext strings.  Merged from 2.0.1.
+       * configure.in:
+               Reconciled libglabels versioning with 2.0.1.
+       
+
 2004-08-14  Jim Evins  <evins@snaught.com>
 
        * configure.in:
index 4cd32a09742a529947da60b0b380c29abaa0638d..ddee81c34d3cc648b52b9889577775b247821a96 100644 (file)
@@ -39,7 +39,7 @@ dnl 5. If any interfaces have been added since the last public release, then inc
 dnl 6. If any interfaces have been removed since the last public release, then set age
 dnl    to 0.
 LIBGLABELS_C=1
-LIBGLABELS_R=0
+LIBGLABELS_R=1
 LIBGLABELS_A=0
 
 LIBGLABELS_VERSION_INFO=${LIBGLABELS_C}:${LIBGLABELS_R}:${LIBGLABELS_A}
index 7bf16288853a1e289fc55e6ad5a98a431d90f63d..e9425319cf3433b7d75726bb2ea5ff92bbc23ef2 100644 (file)
@@ -136,7 +136,14 @@ gl_xml_paper_parse_paper_node (xmlNodePtr paper_node)
 
        name = xmlGetProp (paper_node, "_name");
        if (name != NULL) {
-               name = gettext (name);
+
+               gchar *tmp = gettext (name);
+
+               if (tmp != name) {
+                       g_free (name);
+                       name = g_strdup (tmp);
+               }
+
        } else {
                name = xmlGetProp (paper_node, "name");
        }
index f3fd21b50ca51948396328226a0a5dd1ba4a7c78..4d93409c51693557882e0f07476ae1044bd1fb6d 100644 (file)
@@ -173,7 +173,14 @@ gl_xml_template_parse_template_node (const xmlNodePtr template_node)
 
        description = xmlGetProp (template_node, "_description");
        if (description != NULL) {
-               description = gettext (description);
+
+               gchar *tmp = gettext (description);
+
+               if (tmp != description) {
+                       g_free (description);
+                       description = g_strdup (tmp);
+               }
+
        } else {
                description = xmlGetProp (template_node, "description");
        }
index a6f9168e58c6190c84a4b7a5f980a6ae21097cba..08b9acab1dd70ec76a7d1781986bc0f92306ec25 100644 (file)
@@ -695,7 +695,16 @@ xml191_parse_sheet (xmlNodePtr sheet_node)
 
        description = xmlGetProp (sheet_node, "_description");
        if (description != NULL) {
-               template->description = gettext (description);
+
+               gchar *tmp = gettext (description);
+
+               if (tmp == description) {
+                       template->description = description;
+               } else {
+                       template->description = g_strdup (tmp);
+               }
+
+
        } else {
                template->description = xmlGetProp (sheet_node, "description");
        }