aboutsummaryrefslogtreecommitdiff
path: root/procps (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
| * Make smart_ulltoa return pointer to end (allows for code shink in callers)Denys Vlasenko2013-09-064-12/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta smart_ulltoa5 405 408 +3 smart_ulltoa4 273 276 +3 list_table 1113 1114 +1 scale 36 34 -2 put_lu 55 53 -2 ulltoa6_and_space 19 14 -5 powertop_main 1470 1461 -9 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | Merge branch 'busybox' into mergeRon Yorston2013-08-272-6/+16
|\|
| * pstree: fix theoretically unsafe codeDenys Vlasenko2013-06-281-1/+1
| | | | | | | | | | | | In practice, p->comm is never long enough to trigger the bug, but still. Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * lsof: correct check for symbolic linkThomas De Schampheleire2013-06-271-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Busybox lsof used the d_type field of a 'struct dirent' to verify whether the entry is a symbolic link. This field, however, is not portable. On at least one board [1] I have seen, that field is 0, and the check fails even though the entry is a link. The explicit check for a symbolic link is really only needed to skip the default directory entries '.' and '..'. The directory /proc/<pid>/fd/ should not contain anything else but these two and symbolic links. With these assumptions, this patch replaces the explicit link check with a basic check for '.' and '..' (and any hidden file). In the unlikely case that there are other file types, xmalloc_readlink() will return NULL, and we can skip the entry. [1] A MIPS-based board with glibc 2.9, Linux 2.6.32.27. Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * pstree: stop truncating thread namesMike Frysinger2013-06-191-3/+10
| | | | | | | | | | | | | | | | | | This also fixes a minor buffer overflow when displaying threads as add_proc() only expects COMM_LEN bytes, but we give it one more than that. Reported-by: Dag Wieers <dag@wieers.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
* | Merge branch 'busybox' into mergeRon Yorston2013-04-031-5/+7
|\| | | | | | | | | Conflicts: libbb/lineedit.c
| * libbb: introduce and use strftime_[YYYYMMDD]HHMMSS()Denys Vlasenko2013-03-291-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta strftime_fmt - 53 +53 strftime_YYYYMMDDHHMMSS - 12 +12 strftime_HHMMSS - 12 +12 human_time 44 43 -1 fmtstr_t 9 - -9 step_time 361 345 -16 watch_main 261 232 -29 ------------------------------------------------------------------------------ (add/remove: 3/1 grow/shrink: 0/3 up/down: 77/-55) Total: 22 bytes text data bss dec hex filename 919203 932 17692 937827 e4f63 busybox_old 919209 932 17692 937833 e4f69 busybox_unstripped Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | Merge branch 'busybox' into mergeRon Yorston2013-03-191-1/+1
|\|
| * pgrep: fix a "missing closing paren" build errorDenys Vlasenko2013-02-281-1/+1
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * pgrep: fix -x optionBernhard Walle2013-02-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Because when -x is used (exact match), then we cannot compile the regular expression with REG_NOSUB. The manual page regcomp(3) states in section "Byte offsets": Unless REG_NOSUB was set for the compilation of the pattern buffer, it is possible to obtain substring match addressing information. The problem was detected on an ARM system with glibc 2.16. Signed-off-by: Bernhard Walle <bernhard@bwalle.de> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | Merge branch 'busybox' into mergeRon Yorston2013-02-075-21/+24
|\|
| * ps: seconds_since_boot: uint64_t -> ulongDenys Vlasenko2013-01-261-4/+1
| | | | | | | | | | | | Even if long is 32-bit, 4 billion second uptime isn't likely :) Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * *: reuse more stringsDenys Vlasenko2013-01-221-1/+1
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * ps: fix sscanf format specifier (%l); make uptime unsignedDenys Vlasenko2013-01-221-15/+21
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * whitespace cleanup. no code changesDenys Vlasenko2013-01-142-2/+2
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * whitespace fixes. no code changesDenys Vlasenko2013-01-142-2/+2
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * powertop: fix error messageLauri Hintsala2013-01-041-1/+1
| | | | | | | | | | | | | | | | Application tries to use timer_stats module instead of cpufreq_stats. Error message is printed if opening of the file /proc/timer_stats fails. Signed-off-by: Lauri Hintsala <lauri.hintsala@bluegiga.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
* | Merge branch 'busybox' into mergeRon Yorston2012-10-103-88/+133
|\|
| * libbb: correctness/size tweaks in signal-related helpersDenys Vlasenko2012-09-271-1/+1
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * top: do not touch stdin if -bDenys Vlasenko2012-09-261-10/+16
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * top: fix build failure in !USE_TERMIOS caseDenys Vlasenko2012-09-251-17/+20
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * ps: fix build failure in !DESKTOP caseDenys Vlasenko2012-09-251-3/+3
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * top: implement scrolling up/down (_very_ useful)Denys Vlasenko2012-09-212-74/+110
| | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta handle_input 494 564 +70 top_main 928 947 +19 display_topmem_process_list 363 381 +18 display_process_list 1442 1453 +11 clearmems 38 28 -10 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 4/1 up/down: 118/-10) Total: 108 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | Merge branch 'busybox' into mergeRon Yorston2012-09-073-25/+49
|\| | | | | | | | | | | Conflicts: include/libbb.h shell/ash.c
| * sysctl: implement -qJoshua Kahlenberg2012-09-051-13/+19
| | | | | | | | | | | | | | | | | | | | function old new delta packed_usage 29208 29223 +15 sysctl_act_recursive 605 598 -7 sysctl_main 233 222 -11 Signed-off-by: Joshua Kahlenberg <jbkberg@gmail.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * Move several applets to different install dir:Denys Vlasenko2012-06-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Moved to [/usr]/sbin: addgroup, adduser, delgroup, deluser, arping, chat, ether-wake, fdformat, ifplugd, ip, ipaddr, iplink, iproute, iprule, iptunnel, killall5, readahead, rtcwake, tftpd, add-shell, remove-shell, powertop. Moved to /bin for /usr/bin: kbd_mode. Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * ps: use separate get_uptime() and make it work on non-linux tooMichael Tokarev2012-06-131-11/+29
| | | | | | | | | | | | | | | | Create get_uptime() function in procps/ps.c, and use it rather than relying on linux-specific sysinfo() inline. Signed-off-by: Michael Tokarev <mjt@tls.msk.ru> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | Merge commit '1_20_0' into mergeRon Yorston2012-04-232-2/+80
|\|
| * killall5: don't do STOP/CONT dance if the signal we send is SIGSTOP or SIGCONTDenys Vlasenko2012-04-031-2/+4
| | | | | | | | | | | | | | function old new delta kill_main 913 942 +29 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * lsof: new appletSven Oliver Moll2012-04-011-0/+76
| | | | | | | | | | | | | | | | | | | | text data bss dec hex filename 221 0 0 221 dd lsof.o Signed-off-by: Sven Oliver Moll <busybox@svol.li> Signed-off-by: souf <souf_oued@yahoo.fr> Signed-off-by: Tito Ragusa <farmatito@tiscali.it> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | kill: no special treatment for MINGW32Ron Yorston2012-04-181-2/+0
| |
* | Merge branch 'busybox' into mergeRon Yorston2012-03-232-6/+9
|\| | | | | | | | | Conflicts: Makefile.flags
| * libbb: make xchroot do a chdir("/") after chrootDenys Vlasenko2012-03-081-2/+2
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * kill: fix segfault in arguments parsingAlexey Fomenko2011-12-221-4/+7
| | | | | | | | | | Signed-off-by: Alexey Fomenko <ext-alexey.fomenko@nokia.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | Merge commit 'c0cae52662ccced9df19f19ec94238d1b1e3bd71' into mergeRon Yorston2012-03-235-32/+140
|\| | | | | | | | | | | Conflicts: Makefile.flags scripts/basic/fixdep.c
| * nmeter: fix block i/o count on newer Linux kernelsDenys Vlasenko2011-11-011-12/+38
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * ps: fix for !FEATURE_PS_LONG buildCristian Ionescu-Idbohrn2011-09-291-0/+2
| | | | | | | | | | Signed-off-by: Cristian Ionescu-Idbohrn <cii@axis.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * ps: with -l, show STIME tooFlemming Madsen2011-09-271-16/+21
| | | | | | | | | | Signed-off-by: Flemming Madsen <busybox@themadsens.dk> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * ps: add support for -l for !DESKTOPDenys Vlasenko2011-09-262-19/+94
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * rename archive.h to bb_archive.h. no code changesDenys Vlasenko2011-09-221-1/+1
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * add INIT_G()'s. No code changes.Denys Vlasenko2011-09-211-1/+1
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | Merge commit 'd84b175cb6948eb17f847313bf912174e2f934e1' into mergeRon Yorston2012-03-224-25/+53
|\| | | | | | | | | Conflicts: include/platform.h
| * uptime: more compatible outputDenys Vlasenko2011-08-101-20/+20
| | | | | | | | | | | | | | | | | | | | | | was: 12:59:35 up 1:57, 4 users, load average: 0.11, 0.20, 0.53 is: 12:59:37 up 1:57, 4 users, load average: 0.11, 0.20, 0.53 While at it, switched code to unsigned division. Based on patch by Pere Orga <gotrunks@gmail.com>. Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * uptime: add config flag to allow displaying the number of users currently ↵Pere Orga2011-08-092-13/+31
| | | | | | | | | | | | | | logged on Signed-off-by: Pere Orga <gotrunks@gmail.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * *: work around sysinfo.h versus linux/*.h problemsDenys Vlasenko2011-07-263-0/+10
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | Merge commit '066f39956641300c1e5c6bfe6c11a115cea3e2cf' into mergeRon Yorston2012-03-2212-158/+141
|\| | | | | | | | | Conflicts: procps/ps.c
| * procps: remove PSSCAN_STAT define, users were using it incorrectlyDenys Vlasenko2011-06-181-12/+11
| | | | | | | | | | | | Also contains small cleanups ps. Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * pkill/pgrep: support extended regular expressionsWade Berrier2011-06-101-1/+1
| | | | | | | | | | | | | | | | Done by enabling the REG_EXTENDED and REG_NOSUB regex flags, which also increases compatibility with the procps versions. Signed-off-by: Wade Berrier <wade_berrier@appsig.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * fix breakage caused by 'remove "Options:" string from help texts' commitDenys Vlasenko2011-06-051-0/+1
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * *: remove "Options:" string from help textsDenys Vlasenko2011-06-0512-23/+9
| | | | | | | | | | | | | | function old new delta packed_usage 28706 28623 -83 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>