]> git.notmuchmail.org Git - notmuch/blobdiff - notmuch-count.c
cppcheck: close files during shutdown
[notmuch] / notmuch-count.c
index 50b0c193f04625c794b9ab9287ab6bdd9c4f29da..97281374b22252059fcbf65ff28d426615b2a632 100644 (file)
@@ -204,6 +204,8 @@ notmuch_count_command (notmuch_config_t *config, int argc, char *argv[])
 
     if (batch && opt_index != argc) {
        fprintf (stderr, "--batch and query string are not compatible\n");
+       if (input)
+           fclose (input);
        return EXIT_FAILURE;
     }