int WINAPI WinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance, LPWSTR lpCmdLine, int nShowCmd ) { int status; PJ_UNUSED_ARG(hPrevInstance); PJ_UNUSED_ARG(lpCmdLine); PJ_UNUSED_ARG(nShowCmd); // store the hInstance in global g_hInst = hInstance; status = systest_init(); if (status != 0) goto on_return; status = systest_run(); on_return: systest_deinit(); return status; }
int main() { if (systest_init() != PJ_SUCCESS) return 1; systest_run(); systest_deinit(); return 0; }