"Hello World" core dumps
Mike Harrold
mharrold@cas.org
Tue Nov 30 23:39:00 GMT 1999
>
>
> The following causes a core dump on a Solaris-2.[567] and on a
> i386-linux
>
> #include <stdio.h>
>
> int main()
> {
> unsigned char buf[10000000];
> printf("Hello World\n");
> }
>
> This is a snippet from a real-life application.
>
> Any thoughts?
>
> -- Gaby
>
Check the system limits (ulimit -a from (ba)sh-type shells).
I'd suspect you're exceeding the stack limit.
/Mike
More information about the Gcc-bugs
mailing list