#84 EXIT_FAILURE

closed-fixed
nobody
2001-10-26
2001-10-26
Anonymous
No

<stdlib.h>
Please set correct #define EXIT_FAILURE 1;

in MSVC - #define EXIT_FAILURE 1;
in Linux libc5 - #define EXIT_FAILURE 1;

Discussion

  • Danny Smith
    Danny Smith
    2001-10-26

    • status: open --> closed-fixed
     
  • Danny Smith
    Danny Smith
    2001-10-26

    Logged In: YES
    user_id=11494

    I have applied patch to mingw runtime. MS docs say it is
    1. However, it also says that EXIT_FAILURE,EXIT_SUCCESS
    are return values for atexit. A failed call to atexit

    typedef void (* p_atexit_fn )(void);
    printf ("Failed atexit registration returns %d\n",
    atexit ((p_atexit_fn)NULL) );

    returns -1

    So maybe that is where confusion comes from.

    ANSI just says that EXIT_FAILURE is defined by
    implementation.