Re: EXIT_SUCCESS guaranteed to always be zero?

From: Dan Pop (
Date: 11/27/03

Date: 27 Nov 2003 11:54:47 GMT

In <> Zack Weinberg <> writes:

>You may be wondering 'why define EXIT_SUCCESS at all if 0 has the same
>effect?' It is presumably for symmetry with EXIT_FAILURE.

EXIT_SUCCESS is the C89 way of doing it, while 0 is obviously supported
because it was the (most common) existing practice. Things would
have been much clear if C89 deprecated the usage of 0 for this purpose.


Dan Pop
DESY Zeuthen, RZ group

Relevant Pages

  • Re: Volatile
    ... I'm willing to bet no conforming C99 implementation will take advantage ... C89 code, for no redeeming advantages. ... Dan Pop ...
  • Re: Why is it taking so long?
    ... C99 failed to properly address the *real* needs of the C ... between your extensions to C89 and C99's extensions to C89. ... Dan Pop ...
  • Re: signed and unsigned char
    ... >not undefined behavior. ... Breaking perfectly correct C89 ... Dan Pop ...
  • Re: different "system()" for different OS
    ... Syntax error in C89. ... Try it on an xterm (Unix's most popular terminal emulator for ... Dan Pop ...
  • Re: Standards
    ... >> differences between the draft and C89 that haven't yet been fixed in ... I suspect that, 14 years after the release of C89, all the bugs have been ... reported to the authors and included in the errata. ... Dan Pop ...