some overflow problems fixed -- thanks Holger Kiehl
This commit is contained in:
parent
266d5b708a
commit
713d32a93a
1
NEWS
1
NEWS
@ -5,6 +5,7 @@ avoid warning about -lncurses when not linking (more)
|
|||||||
new names for shared libraries (packagers: watch out!)
|
new names for shared libraries (packagers: watch out!)
|
||||||
"make install" no longer rebuilds everything
|
"make install" no longer rebuilds everything
|
||||||
wchan now '*' for multi-threaded processes
|
wchan now '*' for multi-threaded processes
|
||||||
|
vmstat: some overflow problems fixed -- thanks Holger Kiehl
|
||||||
|
|
||||||
procps-3.2.1 --> procps-3.2.2
|
procps-3.2.1 --> procps-3.2.2
|
||||||
|
|
||||||
|
15
TODO
15
TODO
@ -2,11 +2,14 @@
|
|||||||
|
|
||||||
Implement /usr/proc/bin tools like Solaris has.
|
Implement /usr/proc/bin tools like Solaris has.
|
||||||
The prstat command is interesting, like top in batch mode.
|
The prstat command is interesting, like top in batch mode.
|
||||||
|
SCO has a pstat command.
|
||||||
|
|
||||||
Don't these really belong in the procps package?
|
Don't these really belong in the procps package?
|
||||||
killall pstree fuser lsof who
|
killall pstree fuser lsof who
|
||||||
(they are maintained elsewhere, which causes version problems)
|
(they are maintained elsewhere, which causes version problems)
|
||||||
|
|
||||||
|
OpenBSD has a pfind command.
|
||||||
|
|
||||||
Cache results of dev_to_tty.
|
Cache results of dev_to_tty.
|
||||||
|
|
||||||
---------------------- kernel -------------------------
|
---------------------- kernel -------------------------
|
||||||
@ -59,6 +62,10 @@ Adjust PID-like and PSR-like columns to fit the data.
|
|||||||
The normal PID limit is 5 digits; it can go up to 10.
|
The normal PID limit is 5 digits; it can go up to 10.
|
||||||
The normal CPU limit is 1 digit; it can go to 3 or 4.
|
The normal CPU limit is 1 digit; it can go to 3 or 4.
|
||||||
|
|
||||||
|
don't truncate long usernames
|
||||||
|
|
||||||
|
have a --config option
|
||||||
|
|
||||||
---------------- ps for now, maybe move to libproc ------------------
|
---------------- ps for now, maybe move to libproc ------------------
|
||||||
|
|
||||||
With forest output and a tty named /dev/this_is_my_tty, the position
|
With forest output and a tty named /dev/this_is_my_tty, the position
|
||||||
@ -96,7 +103,13 @@ Add an option to select all processes that a user can kill.
|
|||||||
(related to RUID, EUID, tty, etc. -- but maybe ignore root power)
|
(related to RUID, EUID, tty, etc. -- but maybe ignore root power)
|
||||||
|
|
||||||
Add a nice display option for killing things.
|
Add a nice display option for killing things.
|
||||||
ruser,euser,ppid,pid,pmem,stime,args isn't too bad
|
ruser,euser,ppid,pid,pmem,stime,args
|
||||||
|
|
||||||
|
For RT stuff:
|
||||||
|
pid,tid,class,rtprio,ni,pri,psr,pcpu,stat,wchan:14,comm
|
||||||
|
|
||||||
|
For job control:
|
||||||
|
stat,euid,ruid,tty,tpgid,sess,pgrp,ppid,pid,pcpu,comm
|
||||||
|
|
||||||
Make the column alignment algorithm support this:
|
Make the column alignment algorithm support this:
|
||||||
FOO BAR
|
FOO BAR
|
||||||
|
@ -347,6 +347,7 @@ void getstat(jiff *restrict cuse, jiff *restrict cice, jiff *restrict csys, jiff
|
|||||||
unsigned int *restrict running, unsigned int *restrict blocked,
|
unsigned int *restrict running, unsigned int *restrict blocked,
|
||||||
unsigned int *restrict btime, unsigned int *restrict processes) {
|
unsigned int *restrict btime, unsigned int *restrict processes) {
|
||||||
static int fd;
|
static int fd;
|
||||||
|
unsigned long long llbuf = 0;
|
||||||
int need_vmstat_file = 0;
|
int need_vmstat_file = 0;
|
||||||
int need_proc_scan = 0;
|
int need_proc_scan = 0;
|
||||||
const char* b;
|
const char* b;
|
||||||
@ -376,10 +377,12 @@ void getstat(jiff *restrict cuse, jiff *restrict cice, jiff *restrict csys, jiff
|
|||||||
else need_vmstat_file = 1;
|
else need_vmstat_file = 1;
|
||||||
|
|
||||||
b = strstr(buff, "intr ");
|
b = strstr(buff, "intr ");
|
||||||
if(b) sscanf(b, "intr %u", intr);
|
if(b) sscanf(b, "intr %Lu", &llbuf);
|
||||||
|
*intr = llbuf;
|
||||||
|
|
||||||
b = strstr(buff, "ctxt ");
|
b = strstr(buff, "ctxt ");
|
||||||
if(b) sscanf(b, "ctxt %u", ctxt);
|
if(b) sscanf(b, "ctxt %Lu", &llbuf);
|
||||||
|
*ctxt = llbuf;
|
||||||
|
|
||||||
b = strstr(buff, "btime ");
|
b = strstr(buff, "btime ");
|
||||||
if(b) sscanf(b, "btime %u", btime);
|
if(b) sscanf(b, "btime %u", btime);
|
||||||
|
Loading…
Reference in New Issue
Block a user