Hello!

Yet another one of those things that I absolutely can't understand
has happened to me again. I've written a little program in C,
a simple text editor, using ncurses, and the problems start when I'm
loading a text file into it, storing it in a linked list. The problem
is that when I compile it with -O or -O2, it coredumps, and when I
compile it without optimization, it works fine. I'm sure I've done
something wrong, probably something with malloc(), but how come it
works when I compile it without optimization? There really shouldn't
be a difference in whether the program works or not, right?

I'm using gcc 2.7.2.3, glibc 2.0.6. Everything from the RedHat 5.0 CD.

Linus

-------------------------------------------
Linus Åkerlund    e-mail: [EMAIL PROTECTED]
http://hem2.passagen.se/c64linus/index.html
http://members.xoom.com/vic20/index.html
http://user.tninet.se/~uxm165t/index.htm
-------------------------------------------


--
  PLEASE read the Red Hat FAQ, Tips, Errata and the MAILING LIST ARCHIVES!
http://www.redhat.com/RedHat-FAQ /RedHat-Errata /RedHat-Tips /mailing-lists
         To unsubscribe: mail [EMAIL PROTECTED] with
                       "unsubscribe" as the Subject.

Reply via email to