From: John Keeping Date: Sun, 19 Feb 2017 12:27:48 +0000 (+0000) Subject: ui-shared: don't print path crumbs without a repo X-Git-Url: https://gitweb.ps.run/ps-cgit/commitdiff_plain/1b4ef6783a71962f8b5da3a23f2830f0f0f55ea0?ds=sidebyside;hp=1b4ef6783a71962f8b5da3a23f2830f0f0f55ea0 ui-shared: don't print path crumbs without a repo cgit_print_path_crumbs() can call repolink() which assumes that ctx.repo is non-null. Currently we don't have any commands that set want_vpath without also setting want_repo so it shouldn't be possible to fail this test, but the check in cgit.c is in the wrong order so it is possible to specify a query string like "?p=log&path=foo/bar" to end up here without a valid repository. This was found by American fuzzy lop [0]. [0] http://lcamtuf.coredump.cx/afl/ Signed-off-by: John Keeping ---