[NTLUG:Discuss] OT: C question

Patrick R. Michaud pmichaud at pobox.com
Wed May 10 17:25:12 CDT 2006


On Wed, May 10, 2006 at 05:16:22PM -0500, Fred James wrote:
> All
> I have a C program that if compiled with a "return (0);" as the last 
> line in main(), runs correctly but give a "Bus error(core dump)" message.
> If I compile the same C program with a "exit (0);" as the last line in 
> main(), the run is also correct, and there is no error message.
> 
> What is the difference, please?

How are you declaring "main"?

Does this happen for all programs you compile, or just this specific
one?

Pm



More information about the Discuss mailing list