Skip to content

Commit

Permalink
Move exitHandler to function
Browse files Browse the repository at this point in the history
  • Loading branch information
paddybyers committed Dec 21, 2011
1 parent fb5e0a8 commit 8cf442c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/node.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2691,4 +2691,8 @@ void Dispose() {
V8::Dispose();
}

void Isolate::setExitHandler(void (*exitHandler)()) {
this->exitHandler = exitHandler;
}

} // namespace node
4 changes: 3 additions & 1 deletion src/node.h
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,8 @@ class Isolate {
NODE_EXTERN int Stop(int signum);
NODE_EXTERN static Isolate* New();
NODE_EXTERN void Dispose();
NODE_EXTERN void setExitHandler(void (*)());

v8::Local<v8::Value> ErrnoException(int errorno,
const char *syscall = NULL,
const char *msg = "",
Expand All @@ -146,7 +148,6 @@ class Isolate {
ext_statics statics_;
int exit_status;
int term_signal;
void (*exitHandler)();

Isolate();
~Isolate();
Expand Down Expand Up @@ -245,6 +246,7 @@ class Isolate {

v8::Persistent<v8::Object> binding_cache;
v8::Persistent<v8::Array> module_load_list;
void (*exitHandler)();

};

Expand Down

0 comments on commit 8cf442c

Please sign in to comment.