Move inclusion of emul/fnmatch.h to be after sudo.h for __P

This commit is contained in:
Todd C. Miller
1999-08-28 10:00:22 +00:00
parent 607e54b5e6
commit a067249e1c
3 changed files with 34 additions and 34 deletions

View File

@@ -158,7 +158,7 @@ rangematch(pattern, test, flags)
* consistency with the regular expression syntax.
* J.T. Conklin (conklin@ngai.kaleida.com)
*/
if (negate = (*pattern == '!' || *pattern == '^'))
if ((negate = (*pattern == '!' || *pattern == '^')))
++pattern;
for (ok = 0; (c = *pattern++) != ']';) {

46
parse.c
View File

@@ -39,26 +39,22 @@
#include <stdio.h>
#ifdef STDC_HEADERS
# include <stdlib.h>
# include <stdlib.h>
#endif /* STDC_HEADERS */
#ifdef HAVE_UNISTD_H
# include <unistd.h>
# include <unistd.h>
#endif /* HAVE_UNISTD_H */
#ifdef HAVE_STRING_H
# include <string.h>
# include <string.h>
#endif /* HAVE_STRING_H */
#ifdef HAVE_STRINGS_H
# include <strings.h>
# include <strings.h>
#endif /* HAVE_STRINGS_H */
#if defined(HAVE_FNMATCH) && defined(HAVE_FNMATCH_H)
# include <fnmatch.h>
#else
# ifndef HAVE_FNMATCH
# include "emul/fnmatch.h"
# endif /* HAVE_FNMATCH */
# include <fnmatch.h>
#endif /* HAVE_FNMATCH_H */
#ifdef HAVE_NETGROUP_H
# include <netgroup.h>
# include <netgroup.h>
#endif /* HAVE_NETGROUP_H */
#include <ctype.h>
#include <pwd.h>
@@ -70,26 +66,30 @@
#include <netdb.h>
#include <sys/stat.h>
#if HAVE_DIRENT_H
# include <dirent.h>
# define NAMLEN(dirent) strlen((dirent)->d_name)
# include <dirent.h>
# define NAMLEN(dirent) strlen((dirent)->d_name)
#else
# define dirent direct
# define NAMLEN(dirent) (dirent)->d_namlen
# if HAVE_SYS_NDIR_H
# include <sys/ndir.h>
# endif
# if HAVE_SYS_DIR_H
# include <sys/dir.h>
# endif
# if HAVE_NDIR_H
# include <ndir.h>
# endif
# define dirent direct
# define NAMLEN(dirent) (dirent)->d_namlen
# if HAVE_SYS_NDIR_H
# include <sys/ndir.h>
# endif
# if HAVE_SYS_DIR_H
# include <sys/dir.h>
# endif
# if HAVE_NDIR_H
# include <ndir.h>
# endif
#endif
#include "sudo.h"
#include "parse.h"
#include "interfaces.h"
#ifndef HAVE_FNMATCH
# include "emul/fnmatch.h"
#endif /* HAVE_FNMATCH */
#ifndef lint
static const char rcsid[] = "$Sudo$";
#endif /* lint */

View File

@@ -39,26 +39,22 @@
#include <stdio.h>
#ifdef STDC_HEADERS
# include <stdlib.h>
# include <stdlib.h>
#endif /* STDC_HEADERS */
#ifdef HAVE_UNISTD_H
# include <unistd.h>
# include <unistd.h>
#endif /* HAVE_UNISTD_H */
#ifdef HAVE_STRING_H
# include <string.h>
# include <string.h>
#endif /* HAVE_STRING_H */
#ifdef HAVE_STRINGS_H
# include <strings.h>
# include <strings.h>
#endif /* HAVE_STRINGS_H */
#if defined(HAVE_FNMATCH) && defined(HAVE_FNMATCH_H)
# include <fnmatch.h>
#else
# ifndef HAVE_FNMATCH
# include "emul/fnmatch.h"
# endif /* HAVE_FNMATCH */
# include <fnmatch.h>
#endif /* HAVE_FNMATCH_H */
#ifdef HAVE_NETGROUP_H
# include <netgroup.h>
# include <netgroup.h>
#endif /* HAVE_NETGROUP_H */
#include <ctype.h>
#include <pwd.h>
@@ -76,6 +72,10 @@
#include "parse.h"
#include "interfaces.h"
#ifndef HAVE_FNMATCH
# include "emul/fnmatch.h"
#endif /* HAVE_FNMATCH */
#ifndef lint
static const char rcsid[] = "$Sudo$";
#endif /* lint */