diff --git a/src/file.cc b/src/file.cc index 7c69bf6975..a3130af247 100644 --- a/src/file.cc +++ b/src/file.cc @@ -45,7 +45,7 @@ do { \ TryCatch try_catch; \ (*callback)->Call(Context::GetCurrent()->Global(), argc, argv); \ if(try_catch.HasCaught()) \ - node::fatal_exception(try_catch); \ + node::FatalException(try_catch); \ free(callback); \ } \ } while(0) diff --git a/src/http.cc b/src/http.cc index a9ffddd09d..9723f8df6c 100644 --- a/src/http.cc +++ b/src/http.cc @@ -98,7 +98,7 @@ HTTPConnection::on_message_begin (http_parser *parser) TryCatch try_catch; Local message_handler = on_message->NewInstance(); if (try_catch.HasCaught()) { - fatal_exception(try_catch); + FatalException(try_catch); return -1; } @@ -125,7 +125,7 @@ HTTPConnection::name (http_parser *parser, const char *buf, size_t len) \ Local argv[1] = { String::New(buf, len) }; \ Local ret = callback->Call(message_handler, 1, argv); \ if (ret.IsEmpty()) { \ - fatal_exception(try_catch); \ + FatalException(try_catch); \ return -2; \ } \ if (ret->IsFalse()) return -3; \ @@ -201,7 +201,7 @@ HTTPConnection::on_headers_complete (http_parser *parser) TryCatch try_catch; Local ret = on_headers_complete->Call(message_handler, 0, NULL); if (ret.IsEmpty()) { - fatal_exception(try_catch); + FatalException(try_catch); return -2; } if (ret->IsFalse()) return -3; @@ -246,7 +246,7 @@ HTTPConnection::on_body (http_parser *parser, const char *buf, size_t len) TryCatch try_catch; Local ret = on_body->Call(message_handler, 1, argv); if (ret.IsEmpty()) { - fatal_exception(try_catch); + FatalException(try_catch); return -2; } if (ret->IsFalse()) return -3; @@ -273,7 +273,7 @@ HTTPConnection::on_message_complete (http_parser *parser) TryCatch try_catch; Local ret = on_msg_complete->Call(message_handler, 0, NULL); if (ret.IsEmpty()) { - fatal_exception(try_catch); + FatalException(try_catch); return -2; } if (ret->IsFalse()) return -3; @@ -356,7 +356,7 @@ HTTPServer::OnConnection (struct sockaddr *addr, socklen_t len) HTTPConnection::server_constructor_template->GetFunction()->NewInstance(0, NULL); if (connection_handle.IsEmpty()) { - fatal_exception(try_catch); + FatalException(try_catch); return NULL; } @@ -370,7 +370,7 @@ HTTPServer::OnConnection (struct sockaddr *addr, socklen_t len) Local ret = connection_handler->Call(handle_, 1, argv); if (ret.IsEmpty()) - fatal_exception(try_catch); + FatalException(try_catch); return connection; } diff --git a/src/net.cc b/src/net.cc index e936e38f4c..047df0ef5b 100644 --- a/src/net.cc +++ b/src/net.cc @@ -419,7 +419,7 @@ Connection::OnReceive (const void *buf, size_t len) callback->Call(handle_, argc, argv); if (try_catch.HasCaught()) - fatal_exception(try_catch); + FatalException(try_catch); } #define DEFINE_SIMPLE_CALLBACK(name, symbol) \ @@ -432,7 +432,7 @@ void name () \ TryCatch try_catch; \ callback->Call(handle_, 0, NULL); \ if (try_catch.HasCaught()) \ - node::fatal_exception(try_catch); \ + node::FatalException(try_catch); \ } DEFINE_SIMPLE_CALLBACK(Connection::OnConnect, ON_CONNECT_SYMBOL) @@ -500,7 +500,7 @@ Acceptor::OnConnection (struct sockaddr *addr, socklen_t len) Connection::constructor_template->GetFunction()->NewInstance(0, NULL); if (connection_handle.IsEmpty()) { - fatal_exception(try_catch); + FatalException(try_catch); return NULL; } @@ -514,7 +514,7 @@ Acceptor::OnConnection (struct sockaddr *addr, socklen_t len) Local ret = connection_handler->Call(handle_, 1, argv); if (ret.IsEmpty()) - fatal_exception(try_catch); + FatalException(try_catch); return connection; } diff --git a/src/node.cc b/src/node.cc index 9df86554d1..b974f00cd6 100644 --- a/src/node.cc +++ b/src/node.cc @@ -210,7 +210,7 @@ OnFatalError (const char* location, const char* message) void -node::fatal_exception (TryCatch &try_catch) +node::FatalException (TryCatch &try_catch) { ReportException(&try_catch); ::exit(1); diff --git a/src/node.h b/src/node.h index d207d11124..b22809f780 100644 --- a/src/node.h +++ b/src/node.h @@ -25,7 +25,7 @@ do { \ enum encoding {ASCII, UTF8, RAW}; enum encoding ParseEncoding (v8::Handle encoding_v); -void fatal_exception (v8::TryCatch &try_catch); +void FatalException (v8::TryCatch &try_catch); void eio_warmup (void); // call this before creating a new eio event. class ObjectWrap { diff --git a/src/timer.cc b/src/timer.cc index a2dfd75e45..6b4a39c2bc 100644 --- a/src/timer.cc +++ b/src/timer.cc @@ -40,7 +40,7 @@ Timer::OnTimeout (EV_P_ ev_timer *watcher, int revents) TryCatch try_catch; callback->Call (timer->handle_, 0, NULL); if (try_catch.HasCaught()) - fatal_exception(try_catch); + FatalException(try_catch); /* XXX i'm a bit worried if this is the correct test? * it's rather crutial for memory leaks the conditional here test to see