int main (int argc, char *const *argv) { unsigned int errorCount = 0; oneone = NULL != strstr (argv[0], "11"); if (0 != curl_global_init (CURL_GLOBAL_WIN32)) return 2; errorCount += testInternalGet (0); errorCount += testMultithreadedGet (0); errorCount += testMultithreadedPoolGet (0); errorCount += testUnknownPortGet (0); errorCount += testStopRace (0); errorCount += testExternalGet (); #ifndef WINDOWS errorCount += testInternalGet (MHD_USE_POLL); errorCount += testMultithreadedGet (MHD_USE_POLL); errorCount += testMultithreadedPoolGet (MHD_USE_POLL); errorCount += testUnknownPortGet (MHD_USE_POLL); errorCount += testStopRace (MHD_USE_POLL); #endif #if EPOLL_SUPPORT errorCount += testInternalGet (MHD_USE_EPOLL_LINUX_ONLY); errorCount += testMultithreadedPoolGet (MHD_USE_EPOLL_LINUX_ONLY); errorCount += testUnknownPortGet (MHD_USE_EPOLL_LINUX_ONLY); #endif if (errorCount != 0) fprintf (stderr, "Error (code: %u)\n", errorCount); curl_global_cleanup (); return errorCount != 0; /* 0 == pass */ }
int main (int argc, char *const *argv) { unsigned int errorCount = 0; oneone = (NULL != strrchr (argv[0], (int) '/')) ? (NULL != strstr (strrchr (argv[0], (int) '/'), "11")) : 0; if (0 != curl_global_init (CURL_GLOBAL_WIN32)) return 2; errorCount += testInternalGet (0); errorCount += testMultithreadedGet (0); errorCount += testMultithreadedPoolGet (0); errorCount += testUnknownPortGet (0); errorCount += testStopRace (0); errorCount += testExternalGet (); errorCount += testEmptyGet (0); if (MHD_YES == MHD_is_feature_supported(MHD_FEATURE_POLL)) { errorCount += testInternalGet(MHD_USE_POLL); errorCount += testMultithreadedGet(MHD_USE_POLL); errorCount += testMultithreadedPoolGet(MHD_USE_POLL); errorCount += testUnknownPortGet(MHD_USE_POLL); errorCount += testStopRace(MHD_USE_POLL); errorCount += testEmptyGet(MHD_USE_POLL); } if (MHD_YES == MHD_is_feature_supported(MHD_FEATURE_EPOLL)) { errorCount += testInternalGet(MHD_USE_EPOLL_LINUX_ONLY); errorCount += testMultithreadedPoolGet(MHD_USE_EPOLL_LINUX_ONLY); errorCount += testUnknownPortGet(MHD_USE_EPOLL_LINUX_ONLY); errorCount += testEmptyGet(MHD_USE_EPOLL_LINUX_ONLY); } if (errorCount != 0) fprintf (stderr, "Error (code: %u)\n", errorCount); curl_global_cleanup (); return errorCount != 0; /* 0 == pass */ }