OS/2 Process and Thread API Differences

These APIs are included in your application by including the following definition in your application source file.

#define INCL_DOSPROCESS

OS/2 Process API Differences

The following describes the implementation differences between the OS2Linux library and the real OS/2 process manipulation APIs.

DosExecPgm

APIRET APIENTRY DosExecPgm(PCHAR pObjname, LONG cbObjname, ULONG execFlag,
                           PSZ pArg, PSZ pEnv, PRESULTCODES pRes, PSZ pName);

DosWaitChild

APIRET APIENTRY DosWaitChild(ULONG action, ULONG option, PRESULTCODES pres,
                             PPID ppid, PID pid);

DosKillProcess

APIRET APIENTRY DosKillProcess(ULONG action, PID pid);

DosExitList

APIRET APIENTRY DosExitList(ULONG ordercode, PFNEXITLIST pfn);

OS/2 Thread API Differences

_beginthread

unsigned long _beginthread(void(*start_address )( void * ), 
                           unsigned stack_size, void *arglist);

_endthread

void _endthread(void);

DosCreateThread

APIRET APIENTRY DosCreateThread(PTID ptid, PFNTHREAD pfn, ULONG param,
                                ULONG flag, ULONG cbStack);

DosResumeThread

APIRET APIENTRY DosResumeThread(TID tid);

DosSuspendThread

APIRET APIENTRY DosSuspendThread(TID tid);

DosKillThread

APIRET APIENTRY DosKillThread(TID tid);

DosAllocThreadLocalMemory

APIRET APIENTRY DosAllocThreadLocalMemory(ULONG cb, PULONG *p);

DosFreeThreadLocalMemory

APIRET APIENTRY DosFreeThreadLocalMemory(ULONG *p);

DosWaitThread

APIRET APIENTRY DosWaitThread(PTID ptid, ULONG option);

DosBeep

APIRET APIENTRY DosBeep(ULONG freq, ULONG dur);

DosSleep

APIRET APIENTRY DosSleep(ULONG msec);

DosEnterCritSec

APIRET APIENTRY DosEnterCritSec(VOID);

DosExitCritSec

APIRET APIENTRY DosExitCritSec(VOID);

DosSetPriority

APIRET APIENTRY  DosSetPriority(ULONG scope, ULONG ulClass, LONG delta,
                                ULONG PorTid);

DosGetInfoBlocks

APIRET APIENTRY DosGetInfoBlocks(PTIB *pptib, PPIB *pppib);