fix minor issue
update response headers
correct the header format
do not copy headers to local buffer, use response instead
a little improvement
update logic of reading body
finally, it works, but still so many bugs