From d5075a8a74272b59934676fe248161acaad6a470 Mon Sep 17 00:00:00 2001 From: Kevin Day Date: Wed, 22 Jan 2025 22:46:54 -0600 Subject: [PATCH] Bugfix: f_signal_close() should be setting signal id to -1 and not 0. The signal id is a file descriptor and a non-valid file descriptor is -1 instead of 0. --- level_0/f_signal/c/signal.c | 2 +- level_0/f_signal/c/signal.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/level_0/f_signal/c/signal.c b/level_0/f_signal/c/signal.c index fa1e4c8..28a0702 100644 --- a/level_0/f_signal/c/signal.c +++ b/level_0/f_signal/c/signal.c @@ -41,7 +41,7 @@ extern "C" { return F_status_set_error(F_failure); } - signal->id = 0; + signal->id = -1; return F_okay; } diff --git a/level_0/f_signal/c/signal.h b/level_0/f_signal/c/signal.h index 8625652..40b8f42 100644 --- a/level_0/f_signal/c/signal.h +++ b/level_0/f_signal/c/signal.h @@ -61,7 +61,7 @@ extern "C" { /** * Close an open signal descriptor. * - * The signal.id is set to 0 on success. + * The signal.id is set to -1 on success. * * @param signal * The signal settings. -- 1.8.3.1