X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=server-src%2Famtrmidx.c;h=a2f4c8be1b827b386fe86a38046d2aff0600dd24;hb=d923a3f5bd691defcb8a7013e8ba6521ea2ecca0;hp=6e20da187e4138c5d304e460feaf6e98aae0bc32;hpb=b116e9366c7b2ea2c2eb53b0a13df4090e176235;p=debian%2Famanda diff --git a/server-src/amtrmidx.c b/server-src/amtrmidx.c index 6e20da1..a2f4c8b 100644 --- a/server-src/amtrmidx.c +++ b/server-src/amtrmidx.c @@ -70,6 +70,11 @@ main( int amtrmidx_debug = 0; config_overrides_t *cfg_ovr = NULL; + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("amtrmidx-%s\n", VERSION); + return (0); + } + /* * Configure program for internationalization: * 1) Only set the message locale for now. @@ -184,6 +189,7 @@ main( dbprintf(_("could not open index directory %s\n"), qindexdir); amfree(indexdir); amfree(qindexdir); + g_slist_free(matching_dp); continue; } name_length = 100; @@ -289,6 +295,7 @@ main( amfree(datestamp); amfree(names[i]); } + g_slist_free(matching_dp); amfree(names); amfree(indexdir); amfree(qindexdir);