We must include gettext.h before missing.h as it includes system

headers.  Also add missing DEFAULT_TEXT_DOMAIN defines in sudoers
audit code that does not include sudoers.h.
This commit is contained in:
Todd C. Miller
2014-02-11 09:40:59 -07:00
parent 02d86aafe8
commit 12a1b672c0
22 changed files with 51 additions and 42 deletions

View File

@@ -31,15 +31,15 @@
#include <usersec.h>
#include <uinfo.h>
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h" /* must be included before missing.h */
#include "missing.h"
#include "alloc.h"
#include "fatal.h"
#include "sudo_debug.h"
#include "sudo_util.h"
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h"
#ifdef HAVE_GETUSERATTR
#ifndef HAVE_SETRLIMIT64

View File

@@ -48,13 +48,13 @@
#endif
#include <limits.h>
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h" /* must be included before missing.h */
#include "missing.h"
#include "alloc.h"
#include "fatal.h"
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h"
/*
* If there is no SIZE_MAX or SIZE_T_MAX we have to assume that size_t
* could be signed (as it is on SunOS 4.x). This just means that

View File

@@ -41,7 +41,7 @@
#include <limits.h>
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h"
#include "gettext.h" /* must be included before missing.h */
#include "missing.h"
#include "sudo_debug.h"

View File

@@ -30,7 +30,7 @@
#include <errno.h>
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h"
#include "gettext.h" /* must be included before missing.h */
#include "missing.h"
#include "sudo_debug.h"

View File

@@ -28,15 +28,15 @@
# include "compat/stdbool.h"
#endif /* HAVE_STDBOOL_H */
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h" /* must be included before missing.h */
#include "missing.h"
#include "alloc.h"
#include "fatal.h"
#include "queue.h"
#include "sudo_plugin.h"
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h"
struct sudo_fatal_callback {
SLIST_ENTRY(sudo_fatal_callback) entries;
void (*func)(void);

View File

@@ -30,7 +30,7 @@
#include <grp.h>
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h"
#include "gettext.h" /* must be included before missing.h */
#include "missing.h"
#include "alloc.h"

View File

@@ -45,6 +45,9 @@
#include <errno.h>
#include <limits.h>
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h" /* must be included before missing.h */
#define SUDO_ERROR_WRAP 0
#include "missing.h"
@@ -58,9 +61,6 @@
#include "sudo_util.h"
#include "secure_path.h"
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h"
#ifdef __TANDEM
# define ROOT_UID 65535
#else

View File

@@ -47,6 +47,9 @@
#include <fcntl.h>
#include <time.h>
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h" /* must be included before missing.h */
#include "missing.h"
#include "alloc.h"
#include "fatal.h"
@@ -54,9 +57,6 @@
#include "sudo_debug.h"
#include "sudo_util.h"
#define DEFAULT_TEXT_DOMAIN "sudo"
#include "gettext.h"
/*
* The debug priorities and subsystems are currently hard-coded.
* In the future we might consider allowing plugins to register their