feat(err): implement SErrSuppressError (#28)

Co-authored-by: fallenoak <git@fallenoak.me>
This commit is contained in:
Tristan 'Natrist' Cormier 2025-08-28 23:03:12 -04:00 committed by GitHub
parent 104f18a82a
commit 330ff647ff
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 7 additions and 0 deletions

View file

@ -8,6 +8,7 @@
#endif
static uint32_t s_lasterror = ERROR_SUCCESS;
static uint32_t s_suppress;
[[noreturn]] void SErrDisplayAppFatal(const char* format, ...) {
va_list args;
@ -85,3 +86,7 @@ void SErrSetLastError(uint32_t errorcode) {
uint32_t SErrGetLastError() {
return s_lasterror;
}
void SErrSuppressErrors(uint32_t suppress) {
s_suppress = suppress;
}

View file

@ -116,4 +116,6 @@ void SErrSetLastError(uint32_t errorcode);
uint32_t SErrGetLastError();
void SErrSuppressErrors(uint32_t suppress);
#endif