Skip to content

Commit

Permalink
core, refactor: use default dcheck error handler.
Browse files Browse the repository at this point in the history
  • Loading branch information
xicilion committed Jan 12, 2023
1 parent 5e0b9f1 commit b7dc7ee
Showing 1 changed file with 0 additions and 13 deletions.
13 changes: 0 additions & 13 deletions fibjs/src/base/options.cpp
Expand Up @@ -87,16 +87,6 @@ static void printHelp()
"Documentation can be found at http://fibjs.org\n");
}

#ifdef DEBUG
void asyncLog(int32_t priority, exlib::string msg);
void DcheckHandler(const char* file, int line, const char* message)
{
char p_msg[256];
snprintf(p_msg, sizeof(p_msg), "Assert(DCheck) in %s, line %d: %s", file, line, message);
asyncLog(console_base::C_DEBUG, p_msg);
}
#endif

void options(int32_t& pos, char* argv[])
{
int32_t argc = pos;
Expand Down Expand Up @@ -177,8 +167,5 @@ void options(int32_t& pos, char* argv[])
argc -= df;

v8::V8::SetFlagsFromCommandLine(&argc, argv, true);
#ifdef DEBUG
v8::V8::SetDcheckErrorHandler(DcheckHandler);
#endif
}
}

0 comments on commit b7dc7ee

Please sign in to comment.