Quellcode durchsuchen

libbb.h: always include sys/resource.h

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Denys Vlasenko vor 6 Jahren
Ursprung
Commit
7bcde5f00d

+ 0 - 1
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;

+ 0 - 2
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"

+ 1 - 0
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>

+ 0 - 1
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>

+ 0 - 1
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()  */

+ 0 - 1
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)
 {

+ 0 - 1
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 {

+ 0 - 1
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

+ 0 - 1
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.

+ 0 - 1
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";

+ 0 - 1
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)