aboutsummaryrefslogtreecommitdiff
path: root/client/errcatch.c
diff options
context:
space:
mode:
Diffstat (limited to 'client/errcatch.c')
-rw-r--r--client/errcatch.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/client/errcatch.c b/client/errcatch.c
new file mode 100644
index 0000000..5e39b00
--- /dev/null
+++ b/client/errcatch.c
@@ -0,0 +1,18 @@
+#include "../shared/errcatch.h"
+
+void w2_errcatch_handle_error(w2_s_error *error) {
+ // TODO: handle more error types
+ switch (error->code) {
+ case W2_E_WARN_UNCAUGHT_ERROR: {
+ break;
+ }
+ default: {
+ g_w2_error_uncaught = true;
+#ifdef W2_SIM
+ simwarn("Uncaught/unhandled error found with code 0x%02x\n", error->code);
+#endif
+ }
+ }
+
+ return;
+}