Clean up node environment on exit in main process
This commit is contained in:
parent
d009b3267a
commit
a0605275b9
4 changed files with 29 additions and 0 deletions
|
@ -12,6 +12,8 @@
|
|||
#include "gin/array_buffer.h"
|
||||
#include "gin/v8_initializer.h"
|
||||
|
||||
#include "atom/common/node_includes.h"
|
||||
|
||||
namespace atom {
|
||||
|
||||
JavascriptEnvironment::JavascriptEnvironment()
|
||||
|
@ -46,4 +48,11 @@ bool JavascriptEnvironment::Initialize() {
|
|||
return true;
|
||||
}
|
||||
|
||||
NodeEnvironment::NodeEnvironment(node::Environment* env) : env_(env) {
|
||||
}
|
||||
|
||||
NodeEnvironment::~NodeEnvironment() {
|
||||
node::FreeEnvironment(env_);
|
||||
}
|
||||
|
||||
} // namespace atom
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue