On Mon, 2009-03-16 at 08:42 -0700, Alan Coopersmith wrote: > The casts of function returns to (void) were typically to silence > warnings from lint and similar source checkers that you were ignoring > the return values from the function, and really should be doing some > error checking there. Not sure if those warnings are issued by > any of the source checkers currently used other than lint (gcc -Wall, > sparse, and Coverity are the other three I know of in use).
gcc will only issue warnings for these cases for functions declared with __attribute__((warn_unused_result)). A handful of libc functions are so marked. Given how inconsistently we do the (void) casts within the server, I think it's probably better to just not do them, and leave the paranoia checks to the times when we're being paranoid about chasing down some bug. - ajax
signature.asc
Description: This is a digitally signed message part
_______________________________________________ xorg-devel mailing list [email protected] http://lists.x.org/mailman/listinfo/xorg-devel
