From 2b84af5b80fc943c84a5675ec9cb0975fa35952f Mon Sep 17 00:00:00 2001 From: Jon Siwek Date: Wed, 29 Jan 2014 17:11:20 -0600 Subject: [PATCH] Revert use of HTTP file ID caching for gaps range request content. Just an oversight on my part, this makes the use of file ID caching consistent between the uses of the DataIn and Gap interfaces. --- src/analyzer/protocol/http/HTTP.cc | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/src/analyzer/protocol/http/HTTP.cc b/src/analyzer/protocol/http/HTTP.cc index f9b9496992..3e74ca645c 100644 --- a/src/analyzer/protocol/http/HTTP.cc +++ b/src/analyzer/protocol/http/HTTP.cc @@ -242,11 +242,17 @@ int HTTP_Entity::Undelivered(int64_t len) if ( end_of_data && in_header ) return 0; - cached_file_id = file_mgr->Gap(body_length, len, - http_message->MyHTTP_Analyzer()->GetAnalyzerTag(), - http_message->MyHTTP_Analyzer()->Conn(), - http_message->IsOrig(), - cached_file_id); + if ( is_partial_content ) + file_mgr->Gap(body_length, len, + http_message->MyHTTP_Analyzer()->GetAnalyzerTag(), + http_message->MyHTTP_Analyzer()->Conn(), + http_message->IsOrig()); + else + cached_file_id = file_mgr->Gap(body_length, len, + http_message->MyHTTP_Analyzer()->GetAnalyzerTag(), + http_message->MyHTTP_Analyzer()->Conn(), + http_message->IsOrig(), + cached_file_id); if ( chunked_transfer_state != NON_CHUNKED_TRANSFER ) {