From: Max Kellermann Date: Thu, 25 Dec 2008 13:08:59 +0000 (+0100) Subject: conf: don't free filename in read_rc_file() X-Git-Tag: release-0.13~39 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=11ab59f9d7b3c247bf7b2fecafde9e60e96ea60f;p=ncmpc.git conf: don't free filename in read_rc_file() The code was unused, because free_filename was always 0. --- diff --git a/src/conf.c b/src/conf.c index 4a8bf50..979fd91 100644 --- a/src/conf.c +++ b/src/conf.c @@ -504,15 +504,12 @@ read_rc_file(char *filename) { int fd; int quit = 0; - int free_filename = 0; if (filename == NULL) return -1; if ((fd = open(filename,O_RDONLY)) < 0) { perror(filename); - if (free_filename) - g_free(filename); return -1; } @@ -554,9 +551,6 @@ read_rc_file(char *filename) } } - if (free_filename) - g_free(filename); - return 0; }