chiark / gitweb /
coredump: don't expose the compression level as configuration option
[elogind.git] / src / journal / journalctl.c
index 0619b256b9598a6685eb7205126d4eb7abbd9e90..86453e65c8f9b8c8e362339fba115be1ec50f5b0 100644 (file)
@@ -1290,7 +1290,7 @@ static int setup_keys(void) {
         n = now(CLOCK_REALTIME);
         n /= arg_interval;
 
-        close_nointr_nofail(fd);
+        safe_close(fd);
         fd = mkostemp_safe(k, O_WRONLY|O_CLOEXEC);
         if (fd < 0) {
                 log_error("Failed to open %s: %m", k);
@@ -1389,8 +1389,7 @@ static int setup_keys(void) {
         r = 0;
 
 finish:
-        if (fd >= 0)
-                close_nointr_nofail(fd);
+        safe_close(fd);
 
         if (k) {
                 unlink(k);
@@ -1938,5 +1937,7 @@ int main(int argc, char *argv[]) {
 finish:
         pager_close();
 
+        strv_free(arg_file);
+
         return r < 0 ? EXIT_FAILURE : EXIT_SUCCESS;
 }