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

[Libguestfs] [PATCH libguestfs 7/8] suppress warnings from -Wmissing-noreturn



From: Jim Meyering <meyering redhat com>

Even though these functions are marked as "not implemented yet",
and they will surely return a value once implemented, ...
* src/guestfs.c (select_add_timeout): Declare with noreturn attribute.
(select_remove_timeout): Likewise.
---
 src/guestfs.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/guestfs.c b/src/guestfs.c
index 8491205..0d54d65 100644
--- a/src/guestfs.c
+++ b/src/guestfs.c
@@ -2625,6 +2625,7 @@ select_remove_handle (guestfs_main_loop *mlv, guestfs_h *g, int fd)
 }

 static int
+__attribute__((noreturn))
 select_add_timeout (guestfs_main_loop *mlv, guestfs_h *g, int interval,
                     guestfs_handle_timeout_cb cb, void *data)
 {
@@ -2634,6 +2635,7 @@ select_add_timeout (guestfs_main_loop *mlv, guestfs_h *g, int interval,
 }

 static int
+__attribute__((noreturn))
 select_remove_timeout (guestfs_main_loop *mlv, guestfs_h *g, int timer)
 {
   //struct select_main_loop *ml = (struct select_main_loop *) mlv;
-- 
1.6.4.378.g88f2f


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