This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/34716] application segfaults when compiled with -O2, but works well with -O1
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 8 Jan 2008 20:24:08 -0000
- Subject: [Bug rtl-optimization/34716] application segfaults when compiled with -O2, but works well with -O1
- References: <bug-34716-15595@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #5 from pinskia at gcc dot gnu dot org 2008-01-08 20:24 -------
Can you run your program under gdb and then give the backtrace?
Are you sure that the ioctl does not keep around the buffer so when you return
from main, the buffer becomes invalid?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34716