lkml.org 
[lkml]   [2012]   [Apr]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH][RESEND] do not redefine userspace's NULL #define
On Fri, Apr 13, 2012 at 12:24 PM, Lubos Lunak <l.lunak@suse.cz> wrote:
> GCC's NULL is actually __null, which allows detecting some questionable
> NULL usage and warn about it. Moreover each platform/compiler should have
> its own stddef.h anyway (which is different from linux/stddef.h).
> So there's no good reason to override what the compiler provides.
> Keep the #define conditionally, in order to keep the headers self-contained.

There's no way user should ever include the linux internal stddef.h.

And quite frankly, kernel-external definitions of NULL have
traditionally been pure sh*t (ie plain "0" without the cast to a
pointer), so I'm not entirely convinced about this patch.

So what is the *actual* thing this helps with?

Linus


\
 
 \ /
  Last update: 2012-04-13 21:41    [from the cache]
©2003-2011 Jasper Spaans