r2375 - in glibc-package/branches/glibc-2.6/debian: . patches patches/any
Author: madcoder
Date: 2007-06-18 10:00:34 +0000 (Mon, 18 Jun 2007)
New Revision: 2375
Added:
glibc-package/branches/glibc-2.6/debian/patches/any/submitted-fileops-and-signals.diff
Modified:
glibc-package/branches/glibc-2.6/debian/changelog
glibc-package/branches/glibc-2.6/debian/patches/series
Log:
Closes Bug#429021
Signed-off-by: Pierre Habouzit <madcoder@debian.org>
Modified: glibc-package/branches/glibc-2.6/debian/changelog
===================================================================
--- glibc-package/branches/glibc-2.6/debian/changelog 2007-06-18 10:00:33 UTC (rev 2374)
+++ glibc-package/branches/glibc-2.6/debian/changelog 2007-06-18 10:00:34 UTC (rev 2375)
@@ -91,8 +91,11 @@
restrictions) with depth >= 2 copies.
* debian/control: ${Source-Version} -> ${binary:Version}.
* debian/debhelper.in/nscd.lintian: yes, /var/db for lintian is ok.
+ * patches/any/submitted-fileops-and-signals.diff: fixes libio file
+ operations in presence of recoverable errors.
+ Closes: 429021.
- -- Aurelien Jarno <aurel32@debian.org> Mon, 18 Jun 2007 10:47:18 +0200
+ -- Pierre Habouzit <madcoder@debian.org> Mon, 18 Jun 2007 10:56:35 +0100
glibc (2.5-11) UNRELEASED; urgency=low
Added: glibc-package/branches/glibc-2.6/debian/patches/any/submitted-fileops-and-signals.diff
===================================================================
--- glibc-package/branches/glibc-2.6/debian/patches/any/submitted-fileops-and-signals.diff (rev 0)
+++ glibc-package/branches/glibc-2.6/debian/patches/any/submitted-fileops-and-signals.diff 2007-06-18 10:00:34 UTC (rev 2375)
@@ -0,0 +1,26 @@
+Index: glibc-2.6/libio/fileops.c
+===================================================================
+--- glibc-2.6.orig/libio/fileops.c
++++ glibc-2.6/libio/fileops.c
+@@ -517,10 +517,19 @@
+ fp->_cur_column = INTUSE(_IO_adjust_column) (fp->_cur_column - 1, data,
+ count) + 1;
+ _IO_setg (fp, fp->_IO_buf_base, fp->_IO_buf_base, fp->_IO_buf_base);
+- fp->_IO_write_base = fp->_IO_write_ptr = fp->_IO_buf_base;
+- fp->_IO_write_end = (fp->_mode <= 0
++ if (__builtin_expect (count == to_do, 1))
++ {
++ fp->_IO_write_base = fp->_IO_write_ptr = fp->_IO_buf_base;
++ fp->_IO_write_end = (fp->_mode <= 0
+ && (fp->_flags & (_IO_LINE_BUF+_IO_UNBUFFERED))
+ ? fp->_IO_buf_base : fp->_IO_buf_end);
++ }
++ else if (count > 0 && fp->_IO_write_base == data)
++ {
++ memmove (data, data+count,
++ fp->_IO_write_ptr - fp->_IO_write_base - count);
++ fp->_IO_write_ptr -= count;
++ }
+ return count;
+ }
+
Modified: glibc-package/branches/glibc-2.6/debian/patches/series
===================================================================
--- glibc-package/branches/glibc-2.6/debian/patches/series 2007-06-18 10:00:33 UTC (rev 2374)
+++ glibc-package/branches/glibc-2.6/debian/patches/series 2007-06-18 10:00:34 UTC (rev 2375)
@@ -135,3 +135,4 @@
any/submitted-strfry.diff -p0
any/submitted-strtok.diff -p0
any/local-disable-nscd-host-caching.diff
+any/submitted-fileops-and-signals.diff
Reply to: