From: Chris Metcalf Date: Fri, 6 Jun 2014 22:25:31 +0000 (-0400) Subject: crypt: don't include ufc-crypt.h multiple times X-Git-Tag: glibc-2.20~375 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4d3ae034b7c02b6a94e04ec7a32582379b6f4716;p=platform%2Fupstream%2Fglibc.git crypt: don't include ufc-crypt.h multiple times The file has no inclusion guards, and contains typedefs that cause errors when included multiple times with older (pre-C11) compilers such as gcc 4.4. Save the "#ifdef DOS" content to crypt-private.h even though it's likely not particularly useful. --- diff --git a/ChangeLog b/ChangeLog index 4baa845..3821096 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2014-06-06 Chris Metcalf + + * crypt/crypt-private.h [DOS]: Add some includes taken from the + other files in the crypt directory. + * crypt/crypt.c: Remove duplicate includes. + * crypt/crypt-entry.c: Likewise. + * crypt/crypt_util.c: Likewise. + 2014-06-06 Joseph Myers * Makeconfig (run-program-env): New variable. diff --git a/crypt/crypt-entry.c b/crypt/crypt-entry.c index 2a6e950..f6444df 100644 --- a/crypt/crypt-entry.c +++ b/crypt/crypt-entry.c @@ -34,16 +34,6 @@ #define STATIC static #endif -#ifndef DOS -#include "ufc-crypt.h" -#else -/* - * Thanks to greg%wind@plains.NoDak.edu (Greg W. Wettstein) - * for DOS patches - */ -#include "ufc.h" -#endif -#include "crypt.h" #include "crypt-private.h" /* Prototypes for local functions. */ diff --git a/crypt/crypt-private.h b/crypt/crypt-private.h index ea46a7f..b6a5e07 100644 --- a/crypt/crypt-private.h +++ b/crypt/crypt-private.h @@ -28,7 +28,16 @@ #include #include +#ifndef DOS #include "ufc-crypt.h" +#else +/* + * Thanks to greg%wind@plains.NoDak.edu (Greg W. Wettstein) + * for DOS patches + */ +#include "pl.h" +#include "ufc.h" +#endif #include "crypt.h" /* crypt.c */ diff --git a/crypt/crypt.c b/crypt/crypt.c index 4fb2578..1919210 100644 --- a/crypt/crypt.c +++ b/crypt/crypt.c @@ -23,8 +23,6 @@ * */ -#include "ufc-crypt.h" -#include "crypt.h" #include "crypt-private.h" #ifdef _UFC_32_ diff --git a/crypt/crypt_util.c b/crypt/crypt_util.c index 9381d67..da0a5aa 100644 --- a/crypt/crypt_util.c +++ b/crypt/crypt_util.c @@ -33,17 +33,6 @@ #define STATIC static #endif -#ifndef DOS -#include "ufc-crypt.h" -#else -/* - * Thanks to greg%wind@plains.NoDak.edu (Greg W. Wettstein) - * for DOS patches - */ -#include "pl.h" -#include "ufc.h" -#endif -#include "crypt.h" #include "crypt-private.h" /* Prototypes for local functions. */