Using abort() instead of exit(1)
authordeba
Wed, 06 Sep 2006 09:54:46 +0000
changeset 2198416b0c06b5c8
parent 2197 921923afd57a
child 2199 1229af45cc69
Using abort() instead of exit(1)

If a program is aborted then the call stack can be analyzed with debugger.
The exit(1) does not provides that.
test/test_tools.h
     1.1 --- a/test/test_tools.h	Wed Sep 06 08:36:52 2006 +0000
     1.2 +++ b/test/test_tools.h	Wed Sep 06 09:54:46 2006 +0000
     1.3 @@ -51,7 +51,7 @@
     1.4  #define check(rc, msg) \
     1.5    if(!(rc)) { \
     1.6      std::cerr << __FILE__ ":" << __LINE__ << ": error: " << msg << std::endl; \
     1.7 -    exit(1); \
     1.8 +    abort(); \
     1.9    } else { } \
    1.10  
    1.11  ///Structure returned by \ref addPetersen().