Sack Library Documentation
sack::app::deadstart::PRIORITY_ATEXIT Macro
#define PRIORITY_ATEXIT(name,priority) static void name(void); \
   static class pastejunk(shutdown_,name) {   \
    public:pastejunk(shutdown_,name)() {    \
   RegisterPriorityShutdownProc( name,_WIDE(#name),priority,(void*)this,WIDE__FILE__,__LINE__ );\
    /*name(); / * call on destructor of static object.*/ \
      }  \
    } do_shutdown_##name;     \
    static void name(void)

Defines some code to run at program shutdown time. Allows specification of a priority. Higher priorities are run first.

PRIORITY_ATEXIT( MyOtherShutdown, 153 )
   // run some code probably before most library code dissolves.
   // last to load, first to unload.
Created with a commercial version of Doc-O-Matic. In order to make this message disappear you need to register this software. If you have problems registering this software please contact us at
Copyright (c) 2000+. All rights reserved.
What do you think about this topic? Send feedback!