mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-09 19:35:51 +00:00
fixes bug 119625 "Can't enter new bug or post comments (POSTs turn into GETs)"
r=bbaetz, sr=alecf
This commit is contained in:
parent
974467d75c
commit
61ed1b56b9
@ -2179,8 +2179,7 @@ nsHttpChannel::SetUploadStream(nsIInputStream *stream, const char* contentType,
|
||||
// and so we select POST as the request method if contentType and
|
||||
// contentLength are unspecified.
|
||||
|
||||
mUploadStream = stream;
|
||||
if (mUploadStream) {
|
||||
if (stream) {
|
||||
if (contentType) {
|
||||
if (contentLength < 0) {
|
||||
stream->Available((PRUint32 *) &contentLength);
|
||||
@ -2204,6 +2203,7 @@ nsHttpChannel::SetUploadStream(nsIInputStream *stream, const char* contentType,
|
||||
mUploadStreamHasHeaders = PR_FALSE;
|
||||
mRequestHead.SetMethod(nsHttp::Get); // revert to GET request
|
||||
}
|
||||
mUploadStream = stream;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user