Path: utzoo!attcan!uunet!oddjob!uwvax!vanvleck!uwmcsd1!mailrus!uflorida!novavax!proxftl!bill From: bill@proxftl.UUCP (T. William Wells) Newsgroups: comp.lang.c Subject: Re: is there anything wrong with return(n) from main? Summary: not really Message-ID: <417@proxftl.UUCP> Date: 4 Jul 88 08:50:07 GMT References: <741@vsi.UUCP> Distribution: comp Organization: Proximity Technology, Ft. Lauderdale Lines: 11 In article <741@vsi.UUCP>, friedl@vsi.UUCP (Stephen J. Friedl) writes: > For some unknown reason, I have always felt uncomfortable > doing a return(n) from main: I used exit(n) instead. Can anybody > think of any possible reason why a return is not a good idea? I > have the feeling that my discomfort is entirely unfounded... The only reason I can think of is broken compilers. The two should be equivalent. Of course, one of those broken compilers is the one we have ... on a Sun 3 running SunOS 3.4. It acts as if return (n) were a return (0). [I understand that that has been fixed in a later release.]