@@ -161,9 +161,10 @@ sendResponse :: ByteString -- ^ default server value
161161sendResponse defServer conn ii req reqidxhdr src response = do
162162 hs <- addServerAndDate hs0
163163 if hasBody s then do
164− -- HEAD comes here even if it does not have body. We include HEAD
165− -- responses here so that we generate appropriate content-length
166− -- headers below.
164+ -- The response to HEAD does not have body.
165+ -- But to handle the conditional requests defined RFC 7232 and
166+ -- to generate appropriate content-length, content-range,
167+ -- and status, the response to HEAD is processed here.
167168 --
168169 -- See definition of rsp below for proper body stripping.
169170 sendRsp conn ii ver s hs rsp