From: Stefan Fritsch Date: Tue, 11 Jan 2011 23:10:06 +0000 (+0000) Subject: Save a useless check: X-Git-Tag: 2.3.11~236 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=774529eb10a2f786869b7762746c37f7f8f6c72c;p=thirdparty%2Fapache%2Fhttpd.git Save a useless check: ap_get_request_note() cannot fail unless there is a bug somewhere and if prep_walk_cache() returned NULL, we would just segfault later on. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1057920 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/server/request.c b/server/request.c index 83cc8517a03..9eaee15e4a2 100644 --- a/server/request.c +++ b/server/request.c @@ -333,9 +333,7 @@ static walk_cache_t *prep_walk_cache(apr_size_t t, request_rec *r) * that exists; if not, then create a new walk cache. */ note = ap_get_request_note(r, t); - if (!note) { - return NULL; - } + AP_DEBUG_ASSERT(note != NULL); copy_cache = prev_cache = *note; count = prev_cache ? (prev_cache->count + 1) : 0;