Skip to content

Commit

Permalink
Fixes a potential issue. There was corner situation on which I/O cache
Browse files Browse the repository at this point in the history
could read a couple of uninitialized bytes of memory while turning
'File not found' error codes.


git-svn-id: svn://cherokee-project.com/cherokee/trunk@3602 5dc97367-97f1-0310-9951-d761b3857238
  • Loading branch information
alobbs committed Aug 29, 2009
1 parent 7a5b32b commit 21eccb2
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions cherokee/iocache.c
Expand Up @@ -265,6 +265,12 @@ ioentry_update_stat (cherokee_iocache_entry_t *entry)
if (PRIV(entry)->stat_expiration >= cherokee_bogonow_now) {
TRACE (ENTRIES, "Update stat: %s: updated - skipped\n",
CACHE_ENTRY(entry)->key.buf);

/* Checked, but file didn't exist */
if (PUBL(entry)->state_ret != ret_ok) {
return ret_deny;
}

return ret_ok_and_sent;
}

Expand Down

0 comments on commit 21eccb2

Please sign in to comment.