read_cmdline should close files -- thanks Jim
This commit is contained in:
parent
1f3181bcbf
commit
33a8de391e
@ -318,6 +318,7 @@ int read_cmdline(char *restrict const dst, unsigned sz, unsigned pid){
|
|||||||
if(n==sz) break; // filled the buffer
|
if(n==sz) break; // filled the buffer
|
||||||
if(r==0) break; // EOF
|
if(r==0) break; // EOF
|
||||||
}
|
}
|
||||||
|
close(fd);
|
||||||
if(n){
|
if(n){
|
||||||
int i;
|
int i;
|
||||||
if(n==sz) n--;
|
if(n==sz) n--;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user