X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=notmuch-search.c;h=6f04d9a45d719a37d7c17056d3a3e623560232db;hp=faccaf7deec10961f5f2c2c7bdc5fa9bef4521f7;hb=61f0a5b8ee2adf540106a09c5f83fe634da6beb3;hpb=8bb5b6201ec2cb890655fee6ef7e540f401a4c7e diff --git a/notmuch-search.c b/notmuch-search.c index faccaf7d..6f04d9a4 100644 --- a/notmuch-search.c +++ b/notmuch-search.c @@ -395,6 +395,8 @@ notmuch_search_command (void *ctx, int argc, char *argv[]) int i, ret; output_t output = OUTPUT_SUMMARY; + argc--; argv++; /* skip subcommand argument */ + for (i = 0; i < argc && argv[i][0] == '-'; i++) { if (strcmp (argv[i], "--") == 0) { i++;