Bug 868634 - Remove compartment entry in nsStructuredCloneContainer. r=bz

I can't see what this is supposed to be doing. The one caller defaults to aCx,
and if not, gets and pushes a context associated with the document, restoring
it to the default compartment.

So this only changes the behavior when we use the aCx that comes in from above,
in which case it's totally not clear to me why we would want to get the default
global here.
This commit is contained in:
Bobby Holley 2013-05-07 14:18:03 -07:00
Родитель 12d468cb93
Коммит ff37abce70
1 изменённых файлов: 0 добавлений и 1 удалений

Просмотреть файл

@ -52,7 +52,6 @@ nsStructuredCloneContainer::InitFromVariant(nsIVariant *aData, JSContext *aCx)
// Make sure that we serialize in the right context.
MOZ_ASSERT(aCx == nsContentUtils::GetCurrentJSContext());
JSAutoRequest ar(aCx);
JSAutoCompartment ac(aCx, JS_GetGlobalObject(aCx));
JS_WrapValue(aCx, jsData.address());
uint64_t* jsBytes = nullptr;