]> git.pld-linux.org Git - packages/rpm.git/commitdiff
- more
authorArkadiusz Miśkiewicz <arekm@maven.pl>
Tue, 13 Feb 2007 20:05:52 +0000 (20:05 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    rpm-locale.patch -> 1.2

rpm-locale.patch

index c6370793a6972001c23692f1e831b28331ea5898..a19bfb10d9d2479a60f53ae4304f0e0a7e4cc3d8 100644 (file)
@@ -96,3 +96,49 @@ diff -ur -x Makefile -x Makefile.in -x configure -x po rpm-4.4.2.org/rpmio/rpmio
 +    *dest = '\0';
 +    return result;
 +}
+--- rpm-4.4.2.org/lib/formats.c        2005-01-26 05:46:54.000000000 +0100
++++ rpm-4.4.2/lib/formats.c    2007-02-13 20:50:01.082623000 +0100
+@@ -301,6 +301,7 @@
+     char * t, * te;
+     unsigned long anint = 0;
+     int xx;
++    int freeit = 0;
+ /*@-branchstate@*/
+     switch (type) {
+@@ -308,6 +309,10 @@
+     case RPM_STRING_TYPE:
+       s = data;
+       xtag = "string";
++      /* XXX Force utf8 strings. */
++      s = xstrdup(s);
++      s = xstrtolocale(s);
++      freeit = 1;
+       break;
+     case RPM_BIN_TYPE:
+     { int cpl = b64encode_chars_per_line;
+@@ -321,6 +326,7 @@
+       b64encode_chars_per_line = cpl;
+ /*@=mods@*/
+       xtag = "base64";
++      freeit = 1;
+     } break;
+     case RPM_CHAR_TYPE:
+     case RPM_INT8_TYPE:
+@@ -367,7 +373,7 @@
+     /* XXX s was malloc'd */
+ /*@-branchstate@*/
+-    if (!strcmp(xtag, "base64"))
++    if (freeit)
+       s = _free(s);
+ /*@=branchstate@*/
+@@ -1077,6 +1083,7 @@
+     if (rc && (*data) != NULL) {
+       *data = xstrdup(*data);
++      *data = xstrtolocale(*data);
+       *freeData = 1;
+       return 0;
+     }
This page took 0.0458 seconds and 4 git commands to generate.