diff --git a/src/rc/rc-logger.c b/src/rc/rc-logger.c index b4bd0eae..062ce3d9 100644 --- a/src/rc/rc-logger.c +++ b/src/rc/rc-logger.c @@ -261,12 +261,12 @@ rc_logger_open(const char *level) break; } } + fclose(log); } else { log_error = 1; eerror("Error: fopen(%s) failed: %s", TMPLOG, strerror(errno)); } - fclose(log); fclose(plog); } else { /*