rpms/coreutils/F-9 coreutils-i18n.patch, 1.24, 1.25 coreutils.spec, 1.221, 1.222

Ondrej Vasik ovasik at fedoraproject.org
Mon Mar 2 14:09:28 UTC 2009


Author: ovasik

Update of /cvs/extras/rpms/coreutils/F-9
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv19436

Modified Files:
	coreutils-i18n.patch coreutils.spec 
Log Message:
fix sort bugs (including #485715) for multibyte locales

coreutils-i18n.patch:

Index: coreutils-i18n.patch
===================================================================
RCS file: /cvs/extras/rpms/coreutils/F-9/coreutils-i18n.patch,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- coreutils-i18n.patch	14 Apr 2008 11:06:39 -0000	1.24
+++ coreutils-i18n.patch	2 Mar 2009 14:08:57 -0000	1.25
@@ -1933,7 +1933,7 @@
        if (newlim)
  	lim = newlim;
      }
-@@ -1384,6 +1570,107 @@
+@@ -1384,6 +1570,113 @@
    return ptr;
  }
  
@@ -1946,6 +1946,9 @@
 +  int i;
 +  size_t mblength;
 +  mbstate_t state;
++  if (echar == 0)
++    eword++; /* skip all of end field. */
++
 +
 +  memset (&state, '\0', sizeof(mbstate_t));
 +
@@ -2015,24 +2018,27 @@
 +    }
 +# endif
 +
-+  /* If we're skipping leading blanks, don't start counting characters
-+   *      until after skipping past any leading blanks.  */
-+  if (key->skipsblanks)
-+    while (ptr < lim && ismbblank (ptr, lim - ptr, &mblength))
-+      ptr += mblength;
++  if (echar != 0)
++  {
++    /* If we're skipping leading blanks, don't start counting characters
++     *      until after skipping past any leading blanks.  */
++    if (key->skipsblanks)
++      while (ptr < lim && ismbblank (ptr, lim - ptr, &mblength))
++        ptr += mblength;
 +
-+  memset (&state, '\0', sizeof(mbstate_t));
++    memset (&state, '\0', sizeof(mbstate_t));
 +
-+  /* Advance PTR by ECHAR (if possible), but no further than LIM.  */
-+  for (i = 0; i < echar; i++)
-+    {
-+      GET_BYTELEN_OF_CHAR (lim, ptr, mblength, state);
++    /* Advance PTR by ECHAR (if possible), but no further than LIM.  */
++    for (i = 0; i < echar; i++)
++      {
++        GET_BYTELEN_OF_CHAR (lim, ptr, mblength, state);
 +
-+      if (ptr + mblength > lim)
-+	break;
-+      else
-+	ptr += mblength;
-+    }
++        if (ptr + mblength > lim)
++          break;
++        else
++          ptr += mblength;
++      }
++  }
 +
 +  return ptr;
 +}


Index: coreutils.spec
===================================================================
RCS file: /cvs/extras/rpms/coreutils/F-9/coreutils.spec,v
retrieving revision 1.221
retrieving revision 1.222
diff -u -r1.221 -r1.222
--- coreutils.spec	27 Feb 2009 10:49:41 -0000	1.221
+++ coreutils.spec	2 Mar 2009 14:08:57 -0000	1.222
@@ -1,7 +1,7 @@
 Summary: The GNU core utilities: a set of tools commonly used in shell scripts
 Name:    coreutils
 Version: 6.10
-Release: 34%{?dist}
+Release: 35%{?dist}
 License: GPLv3+
 Group:   System Environment/Base
 Url:     http://www.gnu.org/software/coreutils/
@@ -344,6 +344,10 @@
 /sbin/runuser
 
 %changelog
+* Mon Mar 02 2009 Ondrej Vasik <ovasik at redhat.com> 6.10-35
+- fix sort bugs (including #485715) for multibyte locales
+  as well
+
 * Fri Feb 27 2009 Ondrej Vasik <ovasik at redhat.com> - 6.10-34
 - fix showing ACL's for ls -Z (#487374), fix automatic
   column width for it as well




More information about the fedora-extras-commits mailing list