From 05820b7d403f04b81fa86dc49b304a61f10a623c Mon Sep 17 00:00:00 2001 From: Masaori Koshiba Date: Fri, 1 Jul 2022 09:40:36 +0900 Subject: [PATCH] Add nullptr check of HTTPInfo --- proxy/http/HttpSM.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/proxy/http/HttpSM.cc b/proxy/http/HttpSM.cc index 746794eb5ab..ded6448013d 100644 --- a/proxy/http/HttpSM.cc +++ b/proxy/http/HttpSM.cc @@ -4579,7 +4579,7 @@ HttpSM::parse_range_and_compare(MIMEField *field, int64_t content_length) ranges[nr]._end = end; ++nr; - if (cache_sm.cache_read_vc) { + if (cache_sm.cache_read_vc && t_state.cache_info.object_read) { if (!cache_sm.cache_read_vc->is_pread_capable() && cache_config_read_while_writer == 2) { // write in progress, check if request range not in cache yet HTTPInfo::FragOffset *frag_offset_tbl = t_state.cache_info.object_read->get_frag_table();