X-Git-Url: https://gitweb.ps.run/ps-cgit/blobdiff_plain/72ef913514288bd2aae23509581097bfd3edf8c4..6821d8ea4a64d15b8f284d1af01ab184ef1e76c3:/ui-log.c diff --git a/ui-log.c b/ui-log.c index 354ee08..ee93653 100644 --- a/ui-log.c +++ b/ui-log.c @@ -150,10 +150,13 @@ void cgit_print_log(const char *tip, int ofs, int cnt, char *grep, char *pattern argv[1] = disambiguate_ref(tip); - if (grep && pattern && (!strcmp(grep, "grep") || - !strcmp(grep, "author") || - !strcmp(grep, "committer"))) - argv[argc++] = fmt("--%s=%s", grep, pattern); + if (grep && pattern) { + if (!strcmp(grep, "grep") || !strcmp(grep, "author") || + !strcmp(grep, "committer")) + argv[argc++] = fmt("--%s=%s", grep, pattern); + if (!strcmp(grep, "range")) + argv[1] = pattern; + } if (path) { argv[argc++] = "--";