glibc i zwisy poldka

Jakub Bogusz qboosh w pld-linux.org
Pon, 11 Kwi 2005, 22:19:59 CEST


On Mon, Apr 11, 2005 at 09:54:40PM +0200, Arkadiusz Miskiewicz wrote:
> On Monday 11 of April 2005 21:34, Jakub Bogusz wrote:
> 
> > $ LD_PRELOAD=~qboosh/PLD/BUILD/glibc-2.3.5/builddir/libc.so.6 ./fcookie-tst
> > /tmp/bla 1: ftell 0
> > 2: fseek ret: 0 ftell 0
> > 3: fseek ret: 0 ftell 5
> > 4: char: f fread ret: 1 ftell: 6
> Co w takim razie jeszcze z patchem poldek-cookie.patch jest złego?

Tego jeszcze nie wiem, ale jak na razie dalej wygląda na dziwne
zachowanie glibc, tylko w innym miejscu...

(gdb) bt
#0  gzfseek (stream=0x80bfce0, offset=0xbfffee80, whence=1) at vfile.c:130
#1  0x4ad7a169 in _IO_cookie_seek ()
   from /home/users/qboosh/PLD/BUILD/glibc-2.3.5/builddir/libc.so.6
#2  0x4ad844c4 in _IO_new_file_seekoff ()
   from /home/users/qboosh/PLD/BUILD/glibc-2.3.5/builddir/libc.so.6
#3  0x4ad7a1f9 in _IO_cookie_seekoff ()
   from /home/users/qboosh/PLD/BUILD/glibc-2.3.5/builddir/libc.so.6
#4  0x4ad7b99a in _IO_seekoff_unlocked ()
   from /home/users/qboosh/PLD/BUILD/glibc-2.3.5/builddir/libc.so.6
#5  0x4ad8098b in fseek () from /home/users/qboosh/PLD/BUILD/glibc-2.3.5/builddir/libc.so.6
#6  0x0805651c in pkgfl_restore_f (stream=0x80c1ad8, dirs=0x0, include=0) at pkgfl.c:551
#7  0x0805d705 in pkgdir_load (pkgdir=0x80bd598, depdirs=0x80afde0, ldflags=0) at pkgdir.c:1178
#8  0x08062836 in pkgset_load (ps=0x80a8200, ldflags=0, sources=0x80a4b68) at pkgset-load.c:114
#9  0x0804dde8 in load_pkgset (ldflags=0) at main.c:1570
#10 0x0804ee60 in main (argc=1, argv=0xbffff714) at main.c:2032
(gdb) f 6
#6  0x0805651c in pkgfl_restore_f (stream=0x80c1ad8, dirs=0x0, include=0) at pkgfl.c:551
551         fseek(stream, 1, SEEK_CUR); /* skip final '\n' */
(gdb) f 0
#0  gzfseek (stream=0x80bfce0, offset=0xbfffee80, whence=1) at vfile.c:130
130         z_off_t rc, off = *offset;
(gdb) n
132         rc = gzseek(stream, off, whence);
1: *offset = -4149
(gdb) p off
$6 = -4149

Jak z 1 zrobiło się -4149?


-- 
Jakub Bogusz    http://cyber.cs.net.pl/~qboosh/




Więcej informacji o liście dyskusyjnej pld-devel-pl