diff options
author | Saturneric <[email protected]> | 2023-02-03 13:43:55 +0000 |
---|---|---|
committer | Saturneric <[email protected]> | 2023-02-03 13:43:55 +0000 |
commit | 11d32517c2f6f538209c893c6b0b24572fba1a36 (patch) | |
tree | 0dac14bcad75d9c7c5b5723dc23e6409721966b4 /src/signal.cpp | |
parent | feat: change logging framework to spdlog (diff) | |
download | GpgFrontend-11d32517c2f6f538209c893c6b0b24572fba1a36.tar.gz GpgFrontend-11d32517c2f6f538209c893c6b0b24572fba1a36.zip |
feat: change the log style in source files
Diffstat (limited to 'src/signal.cpp')
-rw-r--r-- | src/signal.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/signal.cpp b/src/signal.cpp index bd4cfdb1..424b97d5 100644 --- a/src/signal.cpp +++ b/src/signal.cpp @@ -43,7 +43,7 @@ extern jmp_buf recover_env; */ void handle_signal(int sig) { static int _repeat_handle_num = 1, last_sig = sig; - LOG(INFO) << "signal caught" << sig; + SPDLOG_INFO("signal caught {}", sig); if (last_sig == sig) _repeat_handle_num++; @@ -51,8 +51,9 @@ void handle_signal(int sig) { _repeat_handle_num = 1, last_sig = sig; if (_repeat_handle_num > 3) { - LOG(INFO) << "The same signal appears three times, execute the termination " - "operation. "; + SPDLOG_INFO( + "The same signal appears three times, execute the termination " + "operation. "); exit(-1); } |