blob: 8624c930cca91a1e211419e7c3b39e3f3aa03d0e [file] [log] [blame]
#include "aos/testing/prevent_exit.h"
#include <stdlib.h>
#include <unistd.h>
#include "glog/logging.h"
namespace aos {
namespace testing {
namespace {
void TerminateExitHandler() {
_exit(EXIT_SUCCESS);
}
} // namespace
void PreventExit() {
CHECK_EQ(atexit(TerminateExitHandler), 0);
}
} // namespace testing
} // namespace aos