DragonFly BSD
DragonFly commits List (threaded) for 2010-07
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

git: <sys/_null.h>: Remove the #include guard.


From: Sascha Wildner <swildner@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Sat, 17 Jul 2010 03:12:52 -0700 (PDT)

commit 1fbab7603d753211896eb67a2eecf1be11a5db09
Author: Sascha Wildner <saw@online.de>
Date:   Sat Jul 17 12:11:23 2010 +0200

    <sys/_null.h>: Remove the #include guard.
    
    POSIX states that various headers (such as <unistd.h>, <stddef.h>,
    <string.h> etc.) all shall provide a definition of NULL. We do that
    by including <sys/_null.h> in these headers.
    
    The problem with the #include guard is that NULL will no longer be
    defined if a program does something like this:
    
    #include <stddef.h>
    #undef NULL
    #include <unistd.h>
    
    <sys/_null.h>'s guard will still be defined and NULL is not getting
    (re-)defined.
    
    Therefore, remove the #include guard. It's just belt and suspenders
    since there is an "#ifndef NULL" around everything in <sys/_null.h>
    anyway.
    
    In-discussion-with: beket

Summary of changes:
 sys/sys/_null.h |    7 -------
 1 files changed, 0 insertions(+), 7 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/1fbab7603d753211896eb67a2eecf1be11a5db09


-- 
DragonFly BSD source repository



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]