blob: cf4a6593245059e9ceab6751f80d66f13f334988 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
/* this file is separate because it is outside of libpd.so */
extern "C" int sys_main(int argc, char **argv);
#if _MSC_VER
#include <windows.h>
#include <stdio.h>
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow) {
__try {
sys_main(__argc,__argv);
} __finally {
printf("caught an exception; stopping\n");
}
}
#else /* not MSVC */
int main(int argc, char **argv) {return sys_main(argc, argv);}
#endif
|