Move inclusion of compat headers up with the system headers.

Now that sudo_dso_public is defined in config.h we don't need sudo_compat.h
before including the compat headers.
This commit is contained in:
Todd C. Miller
2020-08-12 10:07:07 -06:00
parent 985af422d2
commit cbad17a994
14 changed files with 55 additions and 69 deletions

View File

@@ -43,6 +43,11 @@
#include <string.h>
#include <time.h>
#include <unistd.h>
#ifdef HAVE_GETOPT_LONG
# include <getopt.h>
# else
# include "compat/getopt.h"
#endif /* HAVE_GETOPT_LONG */
#if defined(HAVE_OPENSSL)
# include <openssl/ssl.h>
@@ -67,12 +72,6 @@
#include "hostcheck.h"
#include "logsrvd.h"
#ifdef HAVE_GETOPT_LONG
# include <getopt.h>
# else
# include "compat/getopt.h"
#endif /* HAVE_GETOPT_LONG */
#if defined(HAVE_OPENSSL)
# define LOGSRVD_DEFAULT_CIPHER_LST12 "HIGH:!aNULL"
# define LOGSRVD_DEFAULT_CIPHER_LST13 "TLS_AES_256_GCM_SHA384"

View File

@@ -40,6 +40,9 @@
#include <unistd.h>
#include <grp.h>
#include <pwd.h>
#ifndef HAVE_GETADDRINFO
# include "compat/getaddrinfo.h"
#endif
#include "pathnames.h"
#include "sudo_compat.h"
@@ -52,10 +55,6 @@
#include "log_server.pb-c.h"
#include "logsrvd.h"
#ifndef HAVE_GETADDRINFO
# include "compat/getaddrinfo.h"
#endif
#if defined(HAVE_OPENSSL)
# define DEFAULT_CA_CERT_PATH "/etc/ssl/sudo/cacert.pem"
# define DEFAULT_SERVER_CERT_PATH "/etc/ssl/sudo/certs/logsrvd_cert.pem"

View File

@@ -45,6 +45,14 @@
#include <string.h>
#include <time.h>
#include <unistd.h>
#ifndef HAVE_GETADDRINFO
# include "compat/getaddrinfo.h"
#endif
#ifdef HAVE_GETOPT_LONG
# include <getopt.h>
# else
# include "compat/getopt.h"
#endif /* HAVE_GETOPT_LONG */
#if defined(HAVE_OPENSSL)
# include <openssl/ssl.h>
@@ -64,15 +72,6 @@
#include "log_server.pb-c.h"
#include "sendlog.h"
#ifndef HAVE_GETADDRINFO
# include "compat/getaddrinfo.h"
#endif
#ifdef HAVE_GETOPT_LONG
# include <getopt.h>
# else
# include "compat/getopt.h"
#endif /* HAVE_GETOPT_LONG */
#if defined(HAVE_OPENSSL)
# define TLS_HANDSHAKE_TIMEO_SEC 10
#endif