From 64f78d37e209949b03a30dc1964479f80c43d9a9 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Fri, 8 Nov 2013 19:36:49 +0100 Subject: [PATCH] conf: convert runtime check to assertion --- src/conf.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/conf.c b/src/conf.c index 0166f6f..87dd310 100644 --- a/src/conf.c +++ b/src/conf.c @@ -25,6 +25,7 @@ #include "colors.h" #include "screen_list.h" +#include #include #include #include @@ -565,12 +566,11 @@ parse_line(char *line) static int read_rc_file(char *filename) { + assert(filename != NULL); + FILE *file; char line[MAX_LINE_LENGTH]; - if (filename == NULL) - return -1; - file = fopen(filename, "r"); if (file == NULL) { perror(filename); -- 2.30.2