diff options
Diffstat (limited to 'cache.c')
-rw-r--r-- | cache.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/cache.c b/cache.c index df1b4a3..6736a01 100644 --- a/cache.c +++ b/cache.c | |||
@@ -61,8 +61,9 @@ static int open_slot(struct cache_slot *slot) | |||
61 | if (bufz) | 61 | if (bufz) |
62 | bufkeylen = bufz - slot->buf; | 62 | bufkeylen = bufz - slot->buf; |
63 | 63 | ||
64 | slot->match = bufkeylen == slot->keylen && | 64 | if (slot->key) |
65 | !memcmp(slot->key, slot->buf, bufkeylen + 1); | 65 | slot->match = bufkeylen == slot->keylen && |
66 | !memcmp(slot->key, slot->buf, bufkeylen + 1); | ||
66 | 67 | ||
67 | return 0; | 68 | return 0; |
68 | } | 69 | } |