Hi,
the attached program segfaults when using a larger local variable.
Depending on used value I get segfaulst at different locations.
//#define BUFSIZE (9*1024*1024-16*1024) // only segfault #define BUFSIZE (8*1024*1024-16*1024) // hello + segfault //#define BUFSIZE (8*1024*1024-32*1024) // hello + 2nd line
When using last definition of BUFSIZE every thing is fine.
stefan@jarada /home/nfs/extra/src/video/DVB/xlist $ ./test Speicherzugriffsfehler stefan@jarada /home/nfs/extra/src/video/DVB/xlist $ vi test.cc stefan@jarada /home/nfs/extra/src/video/DVB/xlist $ g++ -g test.cc -o test stefan@jarada /home/nfs/extra/src/video/DVB/xlist $ ./test hello ./test: argc = 1 stefan@jarada /home/nfs/extra/src/video/DVB/xlist $ vi test.cc stefan@jarada /home/nfs/extra/src/video/DVB/xlist $ g++ -g test.cc -o test stefan@jarada /home/nfs/extra/src/video/DVB/xlist $ ./test hello Speicherzugriffsfehler stefan@jarada /home/nfs/extra/src/video/DVB/xlist $ ./test stefan@jarada /home/nfs/extra/src/video/DVB/xlist $ ulimit unlimited stefan@jarada /home/nfs/extra/src/video/DVB/xlist $ gcc --version gcc (GCC) 4.1.2 (Gentoo 4.1.2 p1.1) Copyright (C) 2006 Free Software Foundation, Inc. Dies ist freie Software; die Kopierbedingungen stehen in den Quellen. Es gibt KEINE Garantie; auch nicht für MARKTGÄNGIGKEIT oder FÜR SPEZIELLE ZWECKE.