Bug 1128959 - Implement the WHATWG Streams spec - part 17 - Creating FetchStream as a out param in order to avoid JS hazards, r=bz
This commit is contained in:
@@ -1116,12 +1116,9 @@ FetchBody<Derived>::GetBody(JSContext* aCx,
|
||||
return;
|
||||
}
|
||||
|
||||
JS::Rooted<JSObject*> body(aCx,
|
||||
FetchStream::Create(aCx,
|
||||
this,
|
||||
DerivedClass()->GetParentObject(),
|
||||
inputStream,
|
||||
aRv));
|
||||
JS::Rooted<JSObject*> body(aCx);
|
||||
FetchStream::Create(aCx, this, DerivedClass()->GetParentObject(),
|
||||
inputStream, &body, aRv);
|
||||
if (NS_WARN_IF(aRv.Failed())) {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user