summaryrefslogtreecommitdiffstats
path: root/parse.c
diff options
context:
space:
mode:
Diffstat (limited to 'parse.c')
-rw-r--r--parse.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/parse.c b/parse.c
index ad8e89c..98e7dbb 100644
--- a/parse.c
+++ b/parse.c
@@ -1278,7 +1278,7 @@ static struct expr *parse_files0_from(struct parser_state *state, int arg1, int
if (strcmp(from, "-") == 0) {
file = stdin;
} else {
- file = fopen(from, "rb");
+ file = xfopen(from, O_RDONLY | O_CLOEXEC);
}
if (!file) {
parse_error(state, "${blu}%s${rs} ${bld}%s${rs}: %m.\n", arg, from);