Date: Wed, 17 Jun 1998 13:09:02 -0400 (EDT) Message-Id: <199806171709.NAA26180@delorie.com> From: DJ Delorie To: wagray AT taz DOT dra DOT hmg DOT gb CC: djgpp AT delorie DOT com In-reply-to: <6m8ru9$qcl$2@trog.dra.hmg.gb> (wagray@taz.dra.hmg.gb) Subject: Re: Help! Why is my program crashing? Precedence: bulk > :Note also that `main' must return `int'. > > Why is that important? If I just ignore the warning and carry on > using void am I going to have problems? Or is it just one of those > "C things"? Your program will always return *something*. If you don't do it yourself, whatever garbage happens to be in that spot will get used by default. Since many other djgpp programs check this code ("make" is one very important example), it's important that you make sure it returns something reasonable. For example, if you called your program in a Makefile and it returned some non-zero garbage, make would stop at that point, thinking it was an error.