102 lines
2.9 KiB
Diff
102 lines
2.9 KiB
Diff
From de6eba31eaf19e7d8c87cc84aee140e29438336f Mon Sep 17 00:00:00 2001
|
|
From: Alexey Tikhonov <atikhono@redhat.com>
|
|
Date: Fri, 15 Oct 2021 18:23:55 +0200
|
|
Subject: [PATCH 09/17] Removed excessive includes around 'strtonum'
|
|
|
|
Reviewed-by: Pawel Polawski <ppolawsk@redhat.com>
|
|
---
|
|
src/providers/ad/ad_gpo.c | 1 +
|
|
src/util/strtonum.c | 6 ------
|
|
src/util/strtonum.h | 2 --
|
|
src/util/usertools.c | 1 +
|
|
src/util/well_known_sids.c | 1 +
|
|
5 files changed, 3 insertions(+), 8 deletions(-)
|
|
|
|
diff --git a/src/providers/ad/ad_gpo.c b/src/providers/ad/ad_gpo.c
|
|
index f3452176af1275ea393957a8e8c667c1376bf314..8f2fe277e14fe4f430184c03d9913fbbaa3428e9 100644
|
|
--- a/src/providers/ad/ad_gpo.c
|
|
+++ b/src/providers/ad/ad_gpo.c
|
|
@@ -31,6 +31,7 @@
|
|
* ad_gpo_process_cse_send/recv: retrieve policy file data
|
|
*/
|
|
|
|
+#include <ctype.h>
|
|
#include <security/pam_modules.h>
|
|
#include <syslog.h>
|
|
#include <fcntl.h>
|
|
diff --git a/src/util/strtonum.c b/src/util/strtonum.c
|
|
index 22e682b4b22d1de056c578a05a5f81dfdd17df24..8eda8ea25e8896358e13fef7ed4aeeef0df6cdfe 100644
|
|
--- a/src/util/strtonum.c
|
|
+++ b/src/util/strtonum.c
|
|
@@ -19,14 +19,10 @@
|
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
*/
|
|
|
|
-#include <ctype.h>
|
|
#include <stdlib.h>
|
|
#include <errno.h>
|
|
-#include "config.h"
|
|
-#include "util/util.h"
|
|
#include "util/strtonum.h"
|
|
|
|
-/* strtoint32 */
|
|
int32_t strtoint32(const char *nptr, char **endptr, int base)
|
|
{
|
|
long long ret = 0;
|
|
@@ -48,7 +44,6 @@ int32_t strtoint32(const char *nptr, char **endptr, int base)
|
|
}
|
|
|
|
|
|
-/* strtouint32 */
|
|
uint32_t strtouint32(const char *nptr, char **endptr, int base)
|
|
{
|
|
unsigned long long ret = 0;
|
|
@@ -65,7 +60,6 @@ uint32_t strtouint32(const char *nptr, char **endptr, int base)
|
|
}
|
|
|
|
|
|
-/* strtouint16 */
|
|
uint16_t strtouint16(const char *nptr, char **endptr, int base)
|
|
{
|
|
unsigned long long ret = 0;
|
|
diff --git a/src/util/strtonum.h b/src/util/strtonum.h
|
|
index d9c31e9cde87c3af06ab08fbbcadadaf57b593e5..ae493b5f512e31459372bd806e2accccdd827af1 100644
|
|
--- a/src/util/strtonum.h
|
|
+++ b/src/util/strtonum.h
|
|
@@ -22,8 +22,6 @@
|
|
#ifndef _STRTONUM_H_
|
|
#define _STRTONUM_H_
|
|
|
|
-#include <ctype.h>
|
|
-#include <stdlib.h>
|
|
#include <stdint.h>
|
|
|
|
int32_t strtoint32(const char *nptr, char **endptr, int base);
|
|
diff --git a/src/util/usertools.c b/src/util/usertools.c
|
|
index 6f93a4cef288a245a95c2e510a62233f904034fb..1fbde2eb43b1cc4c6dead346a1dafc632a6ec78b 100644
|
|
--- a/src/util/usertools.c
|
|
+++ b/src/util/usertools.c
|
|
@@ -21,6 +21,7 @@
|
|
|
|
#include <pwd.h>
|
|
#include <errno.h>
|
|
+#include <ctype.h>
|
|
#include <talloc.h>
|
|
#include <grp.h>
|
|
|
|
diff --git a/src/util/well_known_sids.c b/src/util/well_known_sids.c
|
|
index 38fe2646faa884f3e14d2b0379b9d9eb7641772c..1f9a7beea8086c6aa34a132e4df85edbf37aca55 100644
|
|
--- a/src/util/well_known_sids.c
|
|
+++ b/src/util/well_known_sids.c
|
|
@@ -20,6 +20,7 @@
|
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
*/
|
|
|
|
+#include <ctype.h>
|
|
#include "util/util.h"
|
|
#include "util/strtonum.h"
|
|
|
|
--
|
|
2.31.1
|
|
|