glibc segfault on "special" long double values is _ok_!?
Bruno Haible
bruno@clisp.org
Thu Jun 7 01:46:00 GMT 2007
Andreas Schwab asked:
> In which way is this different from printf("%s", (char*)1)?
The elementary operations on strings (strlen etc.) crash on (char*)1 too,
therefore one cannot blame 'printf' in particular in the string case.
The elementary operations on long doubles (==, +, isnanl, etc.) produce
no SIGSEGV; in the default settings they do not even produce a SIGFPE.
But 'printf' gives a SIGSEGV.
Bruno
More information about the Libc-alpha
mailing list