summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenys Vlasenko2018-04-08 17:23:27 +0200
committerDenys Vlasenko2018-04-08 17:23:27 +0200
commit7bcde5f00dc3a5c92f36bb6ef6bf849794cd766e (patch)
tree49249dae2b01e39dfe75a04b10b4cdfe91566cd4
parent87a08e476b38ec9ac4ee93c34599b24a7bb284d9 (diff)
downloadbusybox-7bcde5f00dc3a5c92f36bb6ef6bf849794cd766e.zip
busybox-7bcde5f00dc3a5c92f36bb6ef6bf849794cd766e.tar.gz
libbb.h: always include sys/resource.h
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--coreutils/nice.c1
-rw-r--r--debianutils/start_stop_daemon.c2
-rw-r--r--include/libbb.h1
-rw-r--r--init/init.c1
-rw-r--r--loginutils/login.c1
-rw-r--r--loginutils/passwd.c1
-rw-r--r--miscutils/time.c1
-rw-r--r--networking/ntpd.c1
-rw-r--r--runit/chpst.c1
-rw-r--r--shell/shell_common.c1
-rw-r--r--util-linux/renice.c1
11 files changed, 1 insertions, 11 deletions
diff --git a/coreutils/nice.c b/coreutils/nice.c
index aa8b06c..da1696c 100644
--- a/coreutils/nice.c
+++ b/coreutils/nice.c
@@ -22,7 +22,6 @@
//usage: "Change scheduling priority, run PROG\n"
//usage: "\n -n ADJUST Adjust priority by ADJUST"
-#include <sys/resource.h>
#include "libbb.h"
int nice_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
diff --git a/debianutils/start_stop_daemon.c b/debianutils/start_stop_daemon.c
index c8b7fa8..fa77a7e 100644
--- a/debianutils/start_stop_daemon.c
+++ b/debianutils/start_stop_daemon.c
@@ -116,8 +116,6 @@ Misc options:
//usage: )
//usage: "\n -q Quiet"
-#include <sys/resource.h>
-
/* Override ENABLE_FEATURE_PIDFILE */
#define WANT_PIDFILE 1
#include "libbb.h"
diff --git a/include/libbb.h b/include/libbb.h
index ed9a562..c7bf33e 100644
--- a/include/libbb.h
+++ b/include/libbb.h
@@ -41,6 +41,7 @@
#include <poll.h>
#include <sys/ioctl.h>
#include <sys/mman.h>
+#include <sys/resource.h>
#include <sys/socket.h>
#include <sys/stat.h>
#include <sys/time.h>
diff --git a/init/init.c b/init/init.c
index cac165f..6439e2b 100644
--- a/init/init.c
+++ b/init/init.c
@@ -130,7 +130,6 @@
#include "libbb.h"
#include "common_bufsiz.h"
#include <syslog.h>
-#include <sys/resource.h>
#ifdef __linux__
# include <linux/vt.h>
# include <sys/sysinfo.h>
diff --git a/loginutils/login.c b/loginutils/login.c
index fcdb959..25bb520 100644
--- a/loginutils/login.c
+++ b/loginutils/login.c
@@ -64,7 +64,6 @@
#include "libbb.h"
#include "common_bufsiz.h"
#include <syslog.h>
-#include <sys/resource.h>
#if ENABLE_SELINUX
# include <selinux/selinux.h> /* for is_selinux_enabled() */
diff --git a/loginutils/passwd.c b/loginutils/passwd.c
index d0408d8..59f47fc 100644
--- a/loginutils/passwd.c
+++ b/loginutils/passwd.c
@@ -39,7 +39,6 @@
#include "libbb.h"
#include <syslog.h>
-#include <sys/resource.h> /* setrlimit */
static char* new_password(const struct passwd *pw, uid_t myuid, const char *algo)
{
diff --git a/miscutils/time.c b/miscutils/time.c
index 61f0787..7d6a7a2 100644
--- a/miscutils/time.c
+++ b/miscutils/time.c
@@ -32,7 +32,6 @@
//usage: "\n -a Append (else overwrite)"
#include "libbb.h"
-#include <sys/resource.h> /* getrusage */
/* Information on the resources used by a child process. */
typedef struct {
diff --git a/networking/ntpd.c b/networking/ntpd.c
index 8205ab2..6cd4970 100644
--- a/networking/ntpd.c
+++ b/networking/ntpd.c
@@ -94,7 +94,6 @@
#include "libbb.h"
#include <math.h>
#include <netinet/ip.h> /* For IPTOS_LOWDELAY definition */
-#include <sys/resource.h> /* setpriority */
#include <sys/timex.h>
#ifndef IPTOS_LOWDELAY
# define IPTOS_LOWDELAY 0x10
diff --git a/runit/chpst.c b/runit/chpst.c
index 3ecb85c..c2641ce 100644
--- a/runit/chpst.c
+++ b/runit/chpst.c
@@ -135,7 +135,6 @@ ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
//usage: "\n a SIGXCPU after N seconds"
#include "libbb.h"
-#include <sys/resource.h> /* getrlimit */
/*
Five applets here: chpst, envdir, envuidgid, setuidgid, softlimit.
diff --git a/shell/shell_common.c b/shell/shell_common.c
index c978693..9e58ee4 100644
--- a/shell/shell_common.c
+++ b/shell/shell_common.c
@@ -18,7 +18,6 @@
*/
#include "libbb.h"
#include "shell_common.h"
-#include <sys/resource.h> /* getrlimit */
const char defifsvar[] ALIGN1 = "IFS= \t\n";
const char defoptindvar[] ALIGN1 = "OPTIND=1";
diff --git a/util-linux/renice.c b/util-linux/renice.c
index 4670459..ee0fb3c 100644
--- a/util-linux/renice.c
+++ b/util-linux/renice.c
@@ -39,7 +39,6 @@
//usage: "\n -u Process user names"
#include "libbb.h"
-#include <sys/resource.h>
int renice_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
int renice_main(int argc UNUSED_PARAM, char **argv)