Bug 1039846 - Fix bustage. r=bustage CLOSED TREE

--HG--
extra : amend_source : b68f2c23ae47c334e4caedf5f74b4a82bbc90df2
This commit is contained in:
Nikhil Marathe 2014-10-20 13:25:56 -07:00
parent 8a3d0fca50
commit dc1fc9cc4d
2 changed files with 6 additions and 5 deletions

View File

@ -104,6 +104,9 @@ public:
nsresult rv = fetch->Fetch(mResolver);
// Right now we only support async fetch, which should never directly fail.
MOZ_ASSERT(NS_SUCCEEDED(rv));
if (NS_WARN_IF(NS_FAILED(rv))) {
return rv;
}
return NS_OK;
}
};
@ -166,7 +169,7 @@ MainThreadFetchResolver::MainThreadFetchResolver(Promise* aPromise)
void
MainThreadFetchResolver::OnResponseAvailable(InternalResponse* aResponse)
{
NS_ASSERT_OWNINGTHREAD(MainThreadFetchResolver)
NS_ASSERT_OWNINGTHREAD(MainThreadFetchResolver);
AssertIsOnMainThread();
mInternalResponse = aResponse;
@ -178,7 +181,7 @@ MainThreadFetchResolver::OnResponseAvailable(InternalResponse* aResponse)
MainThreadFetchResolver::~MainThreadFetchResolver()
{
NS_ASSERT_OWNINGTHREAD(MainThreadFetchResolver)
NS_ASSERT_OWNINGTHREAD(MainThreadFetchResolver);
}
class WorkerFetchResponseRunnable : public WorkerRunnable

View File

@ -112,11 +112,9 @@ FetchDriver::ContinueFetch(bool aCORSFlag)
return FailWithNetworkError();
}
bool corsPreflight = false;
if (mRequest->Mode() == RequestMode::Cors_with_forced_preflight ||
(mRequest->UnsafeRequest() && (mRequest->HasSimpleMethod() || !mRequest->Headers()->HasOnlySimpleHeaders()))) {
corsPreflight = true;
// FIXME(nsm): Set corsPreflight;
}
mRequest->SetResponseTainting(InternalRequest::RESPONSETAINT_CORS);