libproc buffer extension, better w guess

This commit is contained in:
csmall
2002-05-15 12:54:32 +00:00
parent 264c563f54
commit 4a21f35257
3 changed files with 12 additions and 2 deletions

View File

@ -470,7 +470,7 @@ next_proc: /* get next PID for consideration */
void look_up_our_self(proc_t *p) {
static char path[32], sbuf[512]; /* bufs for stat,statm */
static char path[32], sbuf[1024]; /* bufs for stat,statm */
sprintf(path, "/proc/%d", getpid());
file2str(path, "stat", sbuf, sizeof sbuf);
stat2proc(sbuf, p); /* parse /proc/#/stat */