[tepl] SignalGroup: add a g_return_if_fail() in add()



commit bea10e5dbe406632a7c06221a54b80c07312a655
Author: Sébastien Wilmet <swilmet gnome org>
Date:   Wed Jul 26 15:05:17 2017 +0200

    SignalGroup: add a g_return_if_fail() in add()

 tepl/tepl-signal-group.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
---
diff --git a/tepl/tepl-signal-group.c b/tepl/tepl-signal-group.c
index 2587407..a3e851b 100644
--- a/tepl/tepl-signal-group.c
+++ b/tepl/tepl-signal-group.c
@@ -102,6 +102,7 @@ _tepl_signal_group_add (TeplSignalGroup *group,
                        gulong           signal_handler_id)
 {
        g_return_if_fail (group != NULL);
+       g_return_if_fail (signal_handler_id != 0);
 
        g_array_append_val (group->handler_ids, signal_handler_id);
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]