[Toc][Index]

DosExitList



#define INCL_DOSPROCESS

USHORT  rc = DosExitList(FcnCode_Order, RtnAddress);

USHORT           FcnCode_Order; /* Function request code/Order */
PFNEXITLIST      RtnAddress;    /* Address of routine */

USHORT           rc;            /* return code */

Example 
In this example, TestRoutine is added to the exitlist sequence. Routines 
in the exitlist sequence must use DosExitList instead of DosExit to end. 

#define INCL_DOSPROCESS
#define INCL_VIO
#define ROUTINE_ORDER 0xEE00
#define VIO_HANDLE 0

USHORT rc;

VOID APIENTRY TestRoutine2()
   {
   USHORT r;

   VioWrtTTY("This runs last...\n",         /* String to be written */
             18,                            /* Length of string */
             VIO_HANDLE);                   /* Video handle */
   r = DosExitList(EXLST_EXIT,                   /* Function request
                                                        code/order */
                   (PFNEXITLIST) TestRoutine2);  /* Address of routine */
   }

main()
   {
   rc = DosExitList(EXLST_ADD | ROUTINE_ORDER,   /* Function request
                                                           code/order */
                    (PFNEXITLIST) TestRoutine2); /* Address of routine */
   }


Created using Inf-PHP v.2 (c) 2003 Yuri Prokushev
Created using Inf-HTML v.0.9b (c) 1995 Peter Childs