[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#481543: libc6: low-memory snprintf provokes internal segfault

reopen 481543
tags 481543 -moreinfo, -unreproducible
found 481543 2.7-16

I installed current gcc-snapshot (and upgraded glibc) on otherwise
lenny system, even compiled with gcc-snapshot still runs fine:

Target: x86_64-linux-gnu
gcc version 4.4.0 20081023 (experimental) [trunk revision 141326] (Debian 20081023-1)

$ dpkg -l gcc-4.3 gcc-snapshot libc6

I tried as another user and failed to reproduce the problem.
That led me to discover an error: I meant to use "env --ignore" (-i, not -u),
and the real culprit, which may be a use of freed memory:

   env -i -- /bin/zsh -f -c \
     'ulimit -v 5000;MALLOC_PERTURB_=90 ./a.out %$[5*2**22]d'

The error is exposed only if you set MALLOC_PERTURB_ to a nonzero
value in your environment.

With MALLOC_PERTURB_ it fails also for me.


Reply to: