|
@ -329,7 +329,7 @@ void mytop() |
|
|
{ |
|
|
{ |
|
|
if (chdir("/proc") != 0) { |
|
|
if (chdir("/proc") != 0) { |
|
|
perror("chdir to /proc" ); |
|
|
perror("chdir to /proc" ); |
|
|
return 1; |
|
|
|
|
|
|
|
|
return; |
|
|
} |
|
|
} |
|
|
print_memory(); |
|
|
print_memory(); |
|
|
getkinfo(); |
|
|
getkinfo(); |
|
@ -337,5 +337,5 @@ void mytop() |
|
|
if(prev_proc==NULL) |
|
|
if(prev_proc==NULL) |
|
|
get_procs(); |
|
|
get_procs(); |
|
|
print_procs(prev_proc,proc,1); |
|
|
print_procs(prev_proc,proc,1); |
|
|
return 0; |
|
|
|
|
|
|
|
|
return; |
|
|
} |
|
|
} |