close-on-exec
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23455 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -756,8 +756,11 @@ read_conf_file(const char *fn, CK_USER_TYPE userType, const char *pin)
|
|||||||
|
|
||||||
if (strcasecmp(name, "stdout") == 0)
|
if (strcasecmp(name, "stdout") == 0)
|
||||||
soft_token.logfile = stdout;
|
soft_token.logfile = stdout;
|
||||||
else
|
else {
|
||||||
soft_token.logfile = fopen(name, "a");
|
soft_token.logfile = fopen(name, "a");
|
||||||
|
if (soft_token.logfile)
|
||||||
|
rk_cloexec_file(soft_token.logfile);
|
||||||
|
}
|
||||||
if (soft_token.logfile == NULL)
|
if (soft_token.logfile == NULL)
|
||||||
st_logf("failed to open file: %s\n", name);
|
st_logf("failed to open file: %s\n", name);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user