aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main.c b/src/main.c
index a7533a00f..956cb861a 100644
--- a/src/main.c
+++ b/src/main.c
@@ -1318,7 +1318,7 @@ static ParameterError getparameter(char *flag, /* f or -long-flag */
else
postdata = file2string(file);
if(file && (file != stdin))
- fclose(stdin);
+ fclose(file);
}
else {
GetStr(&postdata, nextarg);
@@ -1626,7 +1626,7 @@ static ParameterError getparameter(char *flag, /* f or -long-flag */
file = fopen(nextarg, "r");
config->writeout = file2string(file);
if(file && (file != stdin))
- fclose(stdin);
+ fclose(file);
}
else
GetStr(&config->writeout, nextarg);