History

Removed the error message and minor changes.

Carlos Montiers committed 12 years ago

Commit 73a7dd71 parent 7c474b41 file · +11 −9Browse files

Unified · Split

win32/lib/crt1.c+11−9
@@ -20,20 +20,22 @@ int main(int argc, char **argv, char **env); · 19 unmodified lines
20int _start(void)20int _start(void)
21{21{
22 __TRY__22 __TRY__
23 int argc; char **argv; char **env; int ret;23 int argc; char **argv; char **env;
24 _startupinfo start_info = {0};24 _startupinfo start_info = {0};
25 25
26 _controlfp(0x10000, 0x30000);26 _controlfp(0x10000, 0x30000);
27 __set_app_type(__CONSOLE_APP);27 __set_app_type(__CONSOLE_APP);
28 if (__getmainargs(&argc, &argv, &env, 0, &start_info)) {
29 // __getmainargs failed because possible few memory on the heap.
30 fprintf(stderr, "Error getting the main args.");
31 // terminate with exit code of 3, similar to abort()
32 ExitProcess(3);
33 }
34 28
35 ret = main(argc, argv, env);29 if (! __getmainargs(&argc, &argv, &env, 0, &start_info))
36 exit(ret);30 {
31 int ret;
32
33 ret = main(argc, argv, env);
34 exit(ret);
35 }
36 // __getmainargs failed because possible few memory on the heap.
37 // end with exit code of 3, similar to abort()
38 ExitProcess(3);
37}39}
38 40
39// =============================================41// =============================================

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t