On Sun, 2006-11-12 at 23:03 +0200, Timo Sirainen wrote:
> If I understood correctly, newer glibcs have added warn_unused_result
> attribute to several functions when compiling with -D_FORTIFY_SOURCE=2.

warn_unused_result means warn if the result is unused even with (void).

This warning is doing what it is designed to do.  -D_FORTIFY_SOURCE=2
means warn when you are ignoring return values and other stuff.  If
chdir fails you should handle that case and not just ignore it like you
are doing.

Thanks,
Andrew Pinski

Reply via email to