Parse the debug args of Node
This commit is contained in:
parent
1d148fe2fb
commit
c1737e5c16
2 changed files with 7 additions and 1 deletions
|
@ -128,6 +128,11 @@ void NodeBindings::Initialize() {
|
|||
node::g_standalone_mode = is_browser_;
|
||||
node::g_upstream_node_mode = false;
|
||||
|
||||
// Parse the debug args.
|
||||
auto args = AtomCommandLine::argv();
|
||||
for (const std::string& arg : args)
|
||||
node::ParseDebugOpt(arg.c_str());
|
||||
|
||||
// Init node.
|
||||
// (we assume node::Init would not modify the parameters under embedded mode).
|
||||
node::Init(nullptr, nullptr, nullptr, nullptr);
|
||||
|
@ -165,6 +170,7 @@ node::Environment* NodeBindings::CreateEnvironment(
|
|||
}
|
||||
|
||||
void NodeBindings::LoadEnvironment(node::Environment* env) {
|
||||
node::node_isolate = env->isolate();
|
||||
if (node::use_debug_agent)
|
||||
node::StartDebug(env, node::debug_wait_connect);
|
||||
|
||||
|
|
2
vendor/node
vendored
2
vendor/node
vendored
|
@ -1 +1 @@
|
|||
Subproject commit a17c44028101d80605556f047a844b3e7ab95677
|
||||
Subproject commit a7e75da3cae48cf6e55fa7c9f13d689f11021795
|
Loading…
Add table
Add a link
Reference in a new issue