Bug 1200869 - Empty the header value for code hygiene; r=sicking

This commit is contained in:
Ehsan Akhgari 2015-09-02 19:53:35 -04:00
parent fef46400c2
commit bb2a119395

View File

@ -1130,6 +1130,7 @@ nsCORSPreflightListener::AddResultToCache(nsIRequest *aRequest)
// The "Access-Control-Allow-Methods" header contains a comma separated
// list of method names.
headerVal.Truncate();
http->GetResponseHeader(NS_LITERAL_CSTRING("Access-Control-Allow-Methods"),
headerVal);
@ -1160,6 +1161,7 @@ nsCORSPreflightListener::AddResultToCache(nsIRequest *aRequest)
// The "Access-Control-Allow-Headers" header contains a comma separated
// list of method names.
headerVal.Truncate();
http->GetResponseHeader(NS_LITERAL_CSTRING("Access-Control-Allow-Headers"),
headerVal);