1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-01-09 17:38:00 +00:00

Fix minor file descriptor leaks. Found by cppcheck, reported by Tim Kosse.

[originally from svn r8656]
This commit is contained in:
Jacob Nevins 2009-09-16 22:28:20 +00:00
parent d992932e1e
commit 94b98ea537
2 changed files with 3 additions and 0 deletions

View File

@ -322,6 +322,7 @@ int cmdline_process_param(char *p, char *value, int need_save, Config *cfg)
cfg->remote_cmd_ptr = command;
cfg->remote_cmd_ptr2 = NULL;
cfg->nopty = TRUE; /* command => no terminal */
fclose(fp);
}
if (!strcmp(p, "-P")) {
RETURN(2);

View File

@ -35,6 +35,8 @@ static int read_dev_urandom(char *buf, int len)
ngot += ret;
}
close(fd);
return 1;
}