Hi Eli,
Eli Zaretskii <[email protected]> writes:
> CC libguile_2.0_la-socket.lo
> socket.c: In function 'scm_fill_sockaddr':
> socket.c:747:16: warning: variable 'scope_id' set but not used
> [-Wunused-but-set-variable]
> unsigned long scope_id = 0;
> ^
How about this?
--8<---------------cut here---------------start------------->8---
diff --git a/libguile/socket.c b/libguile/socket.c
index 3229ac8..beff305 100644
--- a/libguile/socket.c
+++ b/libguile/socket.c
@@ -744,7 +744,7 @@ scm_fill_sockaddr (int fam, SCM address, SCM *args, int
which_arg,
int port;
struct sockaddr_in6 *soka;
unsigned long flowinfo = 0;
- unsigned long scope_id = 0;
+ unsigned long scope_id SCM_UNUSED = 0;
SCM_VALIDATE_CONS (which_arg + 1, *args);
port = scm_to_int (SCM_CAR (*args));
--8<---------------cut here---------------end--------------->8---
See the definition of SCM_UNUSED in __scm.h.
What do you think?
Mark