aboutsummaryrefslogtreecommitdiff
path: root/procps
diff options
context:
space:
mode:
Diffstat (limited to 'procps')
-rw-r--r--procps/free.c17
-rw-r--r--procps/fuser.c3
-rw-r--r--procps/kill.c18
-rw-r--r--procps/pidof.c3
-rw-r--r--procps/ps.c2
-rw-r--r--procps/renice.c17
-rw-r--r--procps/sysctl.c4
-rw-r--r--procps/top.c2
-rw-r--r--procps/uptime.c18
9 files changed, 15 insertions, 69 deletions
diff --git a/procps/free.c b/procps/free.c
index b4163f108..7d8ffa893 100644
--- a/procps/free.c
+++ b/procps/free.c
@@ -4,28 +4,15 @@
4 * 4 *
5 * Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org> 5 * Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org>
6 * 6 *
7 * This program is free software; you can redistribute it and/or modify 7 * Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 *
21 */ 8 */
22 9
23/* getopt not needed */ 10/* getopt not needed */
24 11
12#include "busybox.h"
25#include <stdio.h> 13#include <stdio.h>
26#include <errno.h> 14#include <errno.h>
27#include <stdlib.h> 15#include <stdlib.h>
28#include "busybox.h"
29 16
30int free_main(int argc, char **argv) 17int free_main(int argc, char **argv)
31{ 18{
diff --git a/procps/fuser.c b/procps/fuser.c
index 35d77ed1c..1a4f612f1 100644
--- a/procps/fuser.c
+++ b/procps/fuser.c
@@ -1,3 +1,4 @@
1/* vi: set sw=4 ts=4: */
1/* 2/*
2 * tiny fuser implementation 3 * tiny fuser implementation
3 * 4 *
@@ -7,6 +8,7 @@
7 * GNU Library General Public License 8 * GNU Library General Public License
8 */ 9 */
9 10
11#include "busybox.h"
10#include <stdio.h> 12#include <stdio.h>
11#include <stdlib.h> 13#include <stdlib.h>
12#include <unistd.h> 14#include <unistd.h>
@@ -19,7 +21,6 @@
19#include <sys/stat.h> 21#include <sys/stat.h>
20#include <sys/socket.h> 22#include <sys/socket.h>
21#include <sys/sysmacros.h> 23#include <sys/sysmacros.h>
22#include "busybox.h"
23 24
24#define FUSER_PROC_DIR "/proc" 25#define FUSER_PROC_DIR "/proc"
25#define FUSER_MAX_LINE 255 26#define FUSER_MAX_LINE 255
diff --git a/procps/kill.c b/procps/kill.c
index 90114a493..ca6f4203a 100644
--- a/procps/kill.c
+++ b/procps/kill.c
@@ -5,23 +5,10 @@
5 * Copyright (C) 1995, 1996 by Bruce Perens <bruce@pixar.com>. 5 * Copyright (C) 1995, 1996 by Bruce Perens <bruce@pixar.com>.
6 * Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org> 6 * Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org>
7 * 7 *
8 * This program is free software; you can redistribute it and/or modify 8 * Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 *
22 */ 9 */
23 10
24 11#include "busybox.h"
25#include <stdio.h> 12#include <stdio.h>
26#include <stdlib.h> 13#include <stdlib.h>
27#include <errno.h> 14#include <errno.h>
@@ -30,7 +17,6 @@
30#include <ctype.h> 17#include <ctype.h>
31#include <string.h> 18#include <string.h>
32#include <unistd.h> 19#include <unistd.h>
33#include "busybox.h"
34 20
35#define KILL 0 21#define KILL 0
36#define KILLALL 1 22#define KILLALL 1
diff --git a/procps/pidof.c b/procps/pidof.c
index 4ad6b1567..d9c8dca42 100644
--- a/procps/pidof.c
+++ b/procps/pidof.c
@@ -7,7 +7,7 @@
7 * Licensed under the GPL v2, see the file LICENSE in this tarball. 7 * Licensed under the GPL v2, see the file LICENSE in this tarball.
8 */ 8 */
9 9
10 10#include "busybox.h"
11#include <stdio.h> 11#include <stdio.h>
12#include <stdlib.h> 12#include <stdlib.h>
13#include <errno.h> 13#include <errno.h>
@@ -17,7 +17,6 @@
17#include <string.h> 17#include <string.h>
18#include <sys/types.h> 18#include <sys/types.h>
19#include <unistd.h> 19#include <unistd.h>
20#include "busybox.h"
21 20
22#if ENABLE_FEATURE_PIDOF_SINGLE 21#if ENABLE_FEATURE_PIDOF_SINGLE
23#define _SINGLE_COMPL(a) a 22#define _SINGLE_COMPL(a) a
diff --git a/procps/ps.c b/procps/ps.c
index b6242d208..9dc68395a 100644
--- a/procps/ps.c
+++ b/procps/ps.c
@@ -7,6 +7,7 @@
7 * Licensed under the GPL v2, see the file LICENSE in this tarball. 7 * Licensed under the GPL v2, see the file LICENSE in this tarball.
8 */ 8 */
9 9
10#include "busybox.h"
10#include <stdio.h> 11#include <stdio.h>
11#include <stdlib.h> 12#include <stdlib.h>
12#include <unistd.h> 13#include <unistd.h>
@@ -17,7 +18,6 @@
17#include <string.h> 18#include <string.h>
18#include <termios.h> 19#include <termios.h>
19#include <sys/ioctl.h> 20#include <sys/ioctl.h>
20#include "busybox.h"
21#if ENABLE_SELINUX 21#if ENABLE_SELINUX
22#include <selinux/selinux.h> /* for is_selinux_enabled() */ 22#include <selinux/selinux.h> /* for is_selinux_enabled() */
23#endif 23#endif
diff --git a/procps/renice.c b/procps/renice.c
index 711ed164e..53dc57855 100644
--- a/procps/renice.c
+++ b/procps/renice.c
@@ -4,20 +4,7 @@
4 * 4 *
5 * Copyright (C) 2005 Manuel Novoa III <mjn3@codepoet.org> 5 * Copyright (C) 2005 Manuel Novoa III <mjn3@codepoet.org>
6 * 6 *
7 * This program is free software; you can redistribute it and/or modify 7 * Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 *
21 */ 8 */
22 9
23/* Notes: 10/* Notes:
@@ -32,6 +19,7 @@
32 * following IDs (if any). Multiple switches are allowed. 19 * following IDs (if any). Multiple switches are allowed.
33 */ 20 */
34 21
22#include "busybox.h"
35#include <stdio.h> 23#include <stdio.h>
36#include <stdlib.h> 24#include <stdlib.h>
37#include <string.h> 25#include <string.h>
@@ -39,7 +27,6 @@
39#include <errno.h> 27#include <errno.h>
40#include <unistd.h> 28#include <unistd.h>
41#include <sys/resource.h> 29#include <sys/resource.h>
42#include "busybox.h"
43 30
44#if (PRIO_PROCESS < CHAR_MIN) || (PRIO_PROCESS > CHAR_MAX) 31#if (PRIO_PROCESS < CHAR_MIN) || (PRIO_PROCESS > CHAR_MAX)
45#error Assumption violated : PRIO_PROCESS value 32#error Assumption violated : PRIO_PROCESS value
diff --git a/procps/sysctl.c b/procps/sysctl.c
index 125f13207..5673d293f 100644
--- a/procps/sysctl.c
+++ b/procps/sysctl.c
@@ -1,4 +1,4 @@
1 1/* vi: set sw=4 ts=4: */
2/* 2/*
3 * Sysctl 1.01 - A utility to read and manipulate the sysctl parameters 3 * Sysctl 1.01 - A utility to read and manipulate the sysctl parameters
4 * 4 *
@@ -14,6 +14,7 @@
14 * 14 *
15 */ 15 */
16 16
17#include "busybox.h"
17#include <stdio.h> 18#include <stdio.h>
18#include <stdlib.h> 19#include <stdlib.h>
19#include <unistd.h> 20#include <unistd.h>
@@ -23,7 +24,6 @@
23#include <string.h> 24#include <string.h>
24#include <errno.h> 25#include <errno.h>
25#include <fcntl.h> 26#include <fcntl.h>
26#include "busybox.h"
27 27
28/* 28/*
29 * Function Prototypes 29 * Function Prototypes
diff --git a/procps/top.c b/procps/top.c
index c0d16b658..a97e557aa 100644
--- a/procps/top.c
+++ b/procps/top.c
@@ -28,13 +28,13 @@
28 * GNU Library General Public License 28 * GNU Library General Public License
29 */ 29 */
30 30
31#include "busybox.h"
31#include <sys/types.h> 32#include <sys/types.h>
32#include <stdio.h> 33#include <stdio.h>
33#include <stdlib.h> 34#include <stdlib.h>
34#include <unistd.h> 35#include <unistd.h>
35#include <string.h> 36#include <string.h>
36#include <sys/ioctl.h> 37#include <sys/ioctl.h>
37#include "busybox.h"
38 38
39//#define CONFIG_FEATURE_TOP_CPU_USAGE_PERCENTAGE /* + 2k */ 39//#define CONFIG_FEATURE_TOP_CPU_USAGE_PERCENTAGE /* + 2k */
40 40
diff --git a/procps/uptime.c b/procps/uptime.c
index 7784850ae..c1e7af3a5 100644
--- a/procps/uptime.c
+++ b/procps/uptime.c
@@ -4,20 +4,7 @@
4 * 4 *
5 * Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org> 5 * Copyright (C) 1999-2004 by Erik Andersen <andersen@codepoet.org>
6 * 6 *
7 * This program is free software; you can redistribute it and/or modify 7 * Licensed under the GPL v2 or later, see the file LICENSE in this tarball.
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 *
21 */ 8 */
22 9
23/* This version of uptime doesn't display the number of users on the system, 10/* This version of uptime doesn't display the number of users on the system,
@@ -28,12 +15,11 @@
28 15
29/* getopt not needed */ 16/* getopt not needed */
30 17
31 18#include "busybox.h"
32#include <stdio.h> 19#include <stdio.h>
33#include <time.h> 20#include <time.h>
34#include <errno.h> 21#include <errno.h>
35#include <stdlib.h> 22#include <stdlib.h>
36#include "busybox.h"
37 23
38#ifndef FSHIFT 24#ifndef FSHIFT
39# define FSHIFT 16 /* nr of bits of precision */ 25# define FSHIFT 16 /* nr of bits of precision */