parse response header when CURLOPT_HEADER is true instead of propertry is true