linux: Fix crash when using protocol module early.
This commit is contained in:
parent
d89fb15daf
commit
0a9c371ca2
1 changed files with 6 additions and 0 deletions
|
@ -368,6 +368,12 @@ void Protocol::Initialize(v8::Handle<v8::Object> target) {
|
|||
// Remember the protocol object, used for emitting event later.
|
||||
g_protocol_object.reset(target);
|
||||
|
||||
#if defined(OS_LINUX)
|
||||
// Make sure the job factory has been created.
|
||||
AtomBrowserContext::Get()->url_request_context_getter()->
|
||||
GetURLRequestContext();
|
||||
#endif
|
||||
|
||||
NODE_SET_METHOD(target, "registerProtocol", RegisterProtocol);
|
||||
NODE_SET_METHOD(target, "unregisterProtocol", UnregisterProtocol);
|
||||
NODE_SET_METHOD(target, "isHandledProtocol", IsHandledProtocol);
|
||||
|
|
Loading…
Reference in a new issue