engine: add engine already running error

The engine should not be run more than once.

Signed-off-by: Ronald Caesar <github43132@proton.me>
This commit is contained in:
Ronald Caesar
2026-06-01 23:16:02 -04:00
parent 43b0e647d8
commit 64d0788f1d
2 changed files with 5 additions and 0 deletions
+2
View File
@@ -36,6 +36,8 @@ extern "C"
/// resources.
BAL_ERROR_THREAD_CLEANUP = -8,
BAL_ERROR_ENGINE_ALREADY_RUNNING = -9,
// IR Errors.
//
BAL_ERROR_INSTRUCTION_OVERFLOW = -100,
+3
View File
@@ -27,6 +27,9 @@ bal_error_to_string(const bal_error_t error)
case BAL_ERROR_THREAD_CLEANUP:
string = "could not clean up thread";
break;
case BAL_ERROR_ENGINE_ALREADY_RUNNING:
string = "engine already running";
break;
case BAL_ERROR_UNKNOWN_INSTRUCTION:
string = "failed to decode arm instruction";
break;