diff --git a/.vscode/settings.json b/.vscode/settings.json index 7525efd..cefedf9 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -40,6 +40,94 @@ "files.associations": { ".clang-tidy": "yaml", "filesystem": "cpp", - "regex": "cpp" + "regex": "cpp", + "functional": "cpp", + "algorithm": "cpp", + "any": "cpp", + "array": "cpp", + "atomic": "cpp", + "bit": "cpp", + "bitset": "cpp", + "cctype": "cpp", + "charconv": "cpp", + "chrono": "cpp", + "clocale": "cpp", + "cmath": "cpp", + "codecvt": "cpp", + "compare": "cpp", + "complex": "cpp", + "concepts": "cpp", + "condition_variable": "cpp", + "coroutine": "cpp", + "csignal": "cpp", + "cstdarg": "cpp", + "cstddef": "cpp", + "cstdint": "cpp", + "cstdio": "cpp", + "cstdlib": "cpp", + "cstring": "cpp", + "ctime": "cpp", + "cwchar": "cpp", + "deque": "cpp", + "exception": "cpp", + "expected": "cpp", + "resumable": "cpp", + "format": "cpp", + "forward_list": "cpp", + "fstream": "cpp", + "future": "cpp", + "initializer_list": "cpp", + "iomanip": "cpp", + "ios": "cpp", + "iosfwd": "cpp", + "iostream": "cpp", + "istream": "cpp", + "iterator": "cpp", + "limits": "cpp", + "list": "cpp", + "locale": "cpp", + "map": "cpp", + "memory": "cpp", + "mutex": "cpp", + "new": "cpp", + "numeric": "cpp", + "optional": "cpp", + "ostream": "cpp", + "queue": "cpp", + "random": "cpp", + "ratio": "cpp", + "set": "cpp", + "shared_mutex": "cpp", + "source_location": "cpp", + "sstream": "cpp", + "stack": "cpp", + "stdexcept": "cpp", + "stop_token": "cpp", + "streambuf": "cpp", + "string": "cpp", + "system_error": "cpp", + "thread": "cpp", + "tuple": "cpp", + "type_traits": "cpp", + "typeinfo": "cpp", + "unordered_map": "cpp", + "utility": "cpp", + "variant": "cpp", + "vector": "cpp", + "xfacet": "cpp", + "xhash": "cpp", + "xiosbase": "cpp", + "xlocale": "cpp", + "xlocbuf": "cpp", + "xlocinfo": "cpp", + "xlocmes": "cpp", + "xlocmon": "cpp", + "xlocnum": "cpp", + "xloctime": "cpp", + "xmemory": "cpp", + "xstring": "cpp", + "xtr1common": "cpp", + "xtree": "cpp", + "xutility": "cpp" } } \ No newline at end of file diff --git a/crashelper b/crashelper index eed787c..5ec7814 160000 --- a/crashelper +++ b/crashelper @@ -1 +1 @@ -Subproject commit eed787c1bfc1ed1585843923673e27354be7c0bd +Subproject commit 5ec78141817eef68f92a89b19ea5675f8b5b559b diff --git a/server/main.cpp b/server/main.cpp index 0c1ec5f..3989409 100644 --- a/server/main.cpp +++ b/server/main.cpp @@ -25,6 +25,14 @@ namespace fs = std::filesystem; #include #endif +void signal_handler(int signal) +{ + if (signal == SIGINT) { + fc_recovery_color(); + exit(signal); + } +} + int main(int argc, char* argv[]) { #if defined(GRAB_CRASH) @@ -33,6 +41,7 @@ int main(int argc, char* argv[]) backward::SetDumpFileSavePath(err); backward::SetDumpLogSavePath(err); CRASHELPER_MARK_ENTRY(); + sh.register_user_sig_handler([](int sig) { signal_handler(sig); }); #endif #ifdef _WIN32