ccls/src/messages/exit.cc

14 lines
316 B
C++
Raw Normal View History

2017-12-05 08:14:46 +00:00
#include "message_handler.h"
#include <loguru.hpp>
struct ExitHandler : MessageHandler {
IpcId GetId() const override { return IpcId::Exit; }
void Run(std::unique_ptr<BaseIpcMessage> request) override {
LOG_S(INFO) << "Exiting; got IpcId::Exit";
exit(0);
}
};
REGISTER_MESSAGE_HANDLER(ExitHandler);