about summary refs log tree commit diff
path: root/tests/2021-09-26 * Use tiny UTF-8-aware col -b replacementJune McEnroe2021-09-26 * Install up to cgi-binJune McEnroe2021-09-25 * Clean up up (ugh) somewhat againJune McEnroe2021-09-25 * Sandbox up on both FreeBSD and OpenBSDJune McEnroe2021-09-25 * Make up build away from FreeBSDJune McEnroe2021-09-23 * Call sandbox in CGI modeJune McEnroe2021-09-22 * Support HTTP PUT in upJune McEnroe2021-09-222016-01-16 11:03:07 +0000 committerJason A. Donenfeld <Jason@zx2c4.com>2016-01-17 17:05:39 +0100 commit33bc949a1e927e14479568518bd92e70998e25f8 (patch) tree4b31bd761caeea599aad3dad07d39341a900a112 /tests/valgrind/bin/cgit parentcache: use size_t for string lengths (diff)downloadcgit-pink-33bc949a1e927e14479568518bd92e70998e25f8.tar.gz
cgit-pink-33bc949a1e927e14479568518bd92e70998e25f8.zip
cache: don't check for match with no key
We call open_slot() from cache_ls() without a key since we simply want
to read the path out of the header.  Should the file happen to contain
an empty key then we end up calling memcmp() with NULL and a non-zero
length.  Fix this by assigning slot->match only if a key is set, which
is always will be in the code paths where we use slot->match.

Coverity-id: 13807
Signed-off-by: John Keeping <john@keeping.me.uk>
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions
d=a3b72398ea003c388d80a150a4b12643c69e8391'>Set CGIT_VERSION to "causal agency"June McEnroe2021-06-08 * Merge commit 'f46c4521d761a0b9909e17ef29065c0aa09c7ab7'June McEnroe2021-06-08 * Fetch git .tar.gz for compatibilityJune McEnroe2021-06-08 * Replace freenode with tilde.chatJune McEnroe2021-05-19 * Publish "Swans Are Dead"June McEnroe2021-05-05 * Publish "Time Machine"June McEnroe2021-04-25 * Fix crash trying to print "this commit" on 404sJune McEnroe2021-04-12 * Add some missing justification to "C Style"June McEnroe2021-03-16 * Publish "C Style"June McEnroe2021-03-16 * Add bubger to causal.agency pageJune McEnroe2021-03-14 * Publish "Mailing List"June McEnroe2021-03-04 * Add mailist, liberapay to indexJune McEnroe2021-02-24 * Publish "Operating systems"June McEnroe2021-02-22 * Iterate over text files to generate feedJune McEnroe2021-02-22 * Publish "Unpasswords"June McEnroe2021-02-20 * Add xdimmer to "Using OpenBSD"June McEnroe2021-02-15 * Publish "Using OpenBSD"June McEnroe2021-02-14 * Use owner-filter to add Liberapay donation buttonsJune McEnroe2021-02-04 * Use owner-filter for repo page headersJune McEnroe2021-02-04 * Remove cgit logo using cgitrcJune McEnroe2021-02-04 * Use mtags for sh in source-filterJune McEnroe2021-01-20 * Add all target to git.causal.agency MakefileJune McEnroe2021-01-20 * Remove Lua supportJune McEnroe2021-01-20 * Fix tests for diff spansJune McEnroe2021-01-20 * Use mtags in source-filterJune McEnroe2021-01-20 * Publish "reusing tags"June McEnroe2021-01-17 * Use <pre> and <span> to print diffsJune McEnroe2021-01-17 * Ignore cgit/gitJune McEnroe2021-01-17 * Link to causal.agency cgit from footerJune McEnroe2021-01-17 * Use buffered stdioEric Wong2021-01-17 * Remove redundant title on repo anchorsChris Mayo2021-01-17