diff --git a/iocore/cache/Cache.cc b/iocore/cache/Cache.cc index 0a3cf564148..fcb1438bd22 100644 --- a/iocore/cache/Cache.cc +++ b/iocore/cache/Cache.cc @@ -453,7 +453,7 @@ CacheVC::set_http_info(CacheHTTPInfo *ainfo) } MIMEField *field = ainfo->m_alt->m_response_hdr.field_find(MIME_FIELD_CONTENT_LENGTH, MIME_LEN_CONTENT_LENGTH); - if (field && !field->value_get_int64()) { + if ((field && !field->value_get_int64()) || ainfo->m_alt->m_response_hdr.status_get() == HTTP_STATUS_NO_CONTENT) { f.allow_empty_doc = 1; // Set the object size here to zero in case this is a cache replace where the new object // length is zero but the old object was not.