Bug#781715: libc-bin: ldconfig crashes with SIGSEGV, with large kernel version value.
Package: libc-bin
Version: 2.13-38+deb7u8
Severity: important
Hello, whenever ldconfig is run, the following occurs:
# gdb --args ldconfig
GNU gdb (GDB) 7.4.1-debian
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html> This is free software: you are free
to change and redistribute it. There is NO WARRANTY, to the extent
permitted by law. Type "show copying" and "show warranty" for details.
This GDB was configured as "powerpc-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /sbin/ldconfig...(no debugging symbols
found)...done. (gdb) r
Starting program: /sbin/ldconfig
Can't read symbols from system-supplied DSO at 0x100000: File truncated
FATAL: cannot determine kernel version
Program received signal SIGSEGV, Segmentation fault.
0x1001a258 in ?? ()
(gdb) bt
#0 0x1001a258 in ?? ()
#1 0x1001a22c in ?? ()
#2 0x1001f6e0 in ?? ()
#3 0x1001f4cc in ?? ()
#4 0x10011aa4 in ?? ()
#5 0x10011c24 in ?? ()
#6 0x10006cb8 in ?? ()
#7 0x10006e40 in ?? ()
#8 0x00000000 in ?? ()
(gdb) info registers
r0 0x100cb8b8 269269176
r1 0xbfffec60 3221220448
r2 0x0 0
r3 0x1000 4096
r4 0x10011aa4 268507812
r5 0x1 1
r6 0xfefefeff 4278124287
r7 0x7f7f7f7f 2139062143
r8 0x80 128
r9 0x100ccc68 269274216
r10 0xffff9028 4294938664
r11 0x100d0000 269287424
r12 0x24004084 603996292
r13 0x100d3fb0 269303728
r14 0x0 0
r15 0x0 0
r16 0x0 0
r17 0x0 0
r18 0x0 0
r19 0x0 0
r20 0x0 0
r21 0x27 39
r22 0x0 0
r23 0x0 0
r24 0x7 7
r25 0xbfffece0 3221220576
r26 0x1 1
r27 0xbfffed24 3221220644
r28 0x100b6458 269182040
r29 0x100d0000 269287424
r30 0x100ccc5c 269274204
r31 0x0 0
pc 0x1001a258 0x1001a258
msr 0xd932 55602
cr 0x24004084 603996292
lr 0x1001a22c 0x1001a22c
ctr 0x1001f6c0 268564160
xer 0x20000000 536870912
orig_r3 0x7 7
trap 0x300 768
(gdb)
It is possible that it cannot handle my extremely high kernel version
number of 3.14.3720150331. The value 3720150331 exceeds the length of a
signed 32-bit integer. I have never had such a problem before with
lower valued version numbers.
The error appears in a macro called DL_SYSDEP_OSCHECK inside of:
sysdeps/unix/sysv/linux/dl-osinfo.h
''int version = _dl_discover_osversion ();'', which is a signed 32-bit
value.
In sysdeps/unix/sysv/linux/dl-sysdep.c (where _dl_discover_osversion is
defined) that function it operates in an unsigned manner, however it
returns a signed value rather than an unsigned (cast to signed).
-- System Information:
Debian Release: 7.8
APT prefers stable
APT policy: (500, 'stable')
Architecture: powerpc (ppc)
Kernel: Linux 3.14.3720150331
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
-- no debconf information
Reply to: