mirror of
https://gitee.com/openharmony/arkcompiler_ets_runtime
synced 2024-12-04 00:43:40 +00:00
Fix bug about import hsp in worker
issues:https://gitee.com/openharmony/arkcompiler_ets_runtime/issues/I75MLH?from=project-issue Signed-off-by: changjiaxing <changjiaxing2@huawei.com> Change-Id: If26673b59c4359f9fce2e58f3fe0cfcd720e0d2a
This commit is contained in:
parent
b266e4cbc8
commit
321519f27e
@ -1324,6 +1324,7 @@ public:
|
||||
static void SetModuleName(EcmaVM *vm, const std::string &moduleName);
|
||||
static std::string GetModuleName(EcmaVM *vm);
|
||||
static void AllowCrossThreadExecution(EcmaVM *vm);
|
||||
static void SynchronizVMInfo(EcmaVM *vm, const EcmaVM *hostVM);
|
||||
|
||||
private:
|
||||
static int vmCount_;
|
||||
|
@ -3064,4 +3064,14 @@ void JSNApi::AllowCrossThreadExecution(EcmaVM *vm)
|
||||
vm->GetAssociatedJSThread()->EnableCrossThreadExecution();
|
||||
}
|
||||
|
||||
void JSNApi::SynchronizVMInfo(EcmaVM *vm, const EcmaVM *hostVM)
|
||||
{
|
||||
vm->SetBundleName(hostVM->GetBundleName());
|
||||
vm->SetModuleName(hostVM->GetModuleName());
|
||||
vm->SetAssetPath(hostVM->GetAssetPath());
|
||||
vm->SetIsBundlePack(hostVM->IsBundlePack());
|
||||
vm->GetModuleManager()->SetExecuteMode(hostVM->GetModuleManager()->GetCurrentMode());
|
||||
vm->SetResolveBufferCallback(hostVM->GetResolveBufferCallback());
|
||||
}
|
||||
|
||||
} // namespace panda
|
||||
|
Loading…
Reference in New Issue
Block a user