agent: Fix warning about required glib version
authorNirbheek Chauhan <nirbheek@centricular.com>
Fri, 18 Mar 2022 07:05:49 +0000 (12:35 +0530)
committerNirbheek Chauhan <nirbheek@centricular.com>
Mon, 21 Mar 2022 15:51:06 +0000 (15:51 +0000)
../agent/discovery.c: In function ‘on_refresh_remove_timeout’:
../agent/discovery.c:203:13: warning: Not available before 2.60
  203 |       G_GNUC_FALLTHROUGH;
      |             ^~~~~~~~~~~~~

../agent/conncheck.c: In function ‘priv_turn_allocate_refresh_retransmissions_tick_agent_locked’:
../agent/conncheck.c:1656:13: warning: Not available before 2.60
 1656 |       G_GNUC_FALLTHROUGH;
      |             ^~~~~~~~~~~~~

The comment /* fall through */ is enough to cause GCC and Clang to not
emit the implicit-fallthrough warning.

agent/conncheck.c
agent/discovery.c

index cd8f9cf..d99f948 100644 (file)
@@ -1653,7 +1653,7 @@ static gboolean priv_turn_allocate_refresh_retransmissions_tick_agent_locked (
       agent_socket_send (cand->nicesock, &cand->server,
           stun_message_length (&cand->stun_message), (gchar *)cand->stun_buffer);
 
-      G_GNUC_FALLTHROUGH;
+      /* fall through */
     case STUN_USAGE_TIMER_RETURN_SUCCESS:
       agent_timeout_add_with_context (agent, &cand->tick_source,
           "Candidate TURN refresh", stun_timer_remainder (&cand->timer),
index 872c309..4231804 100644 (file)
@@ -200,7 +200,7 @@ static gboolean on_refresh_remove_timeout (NiceAgent *agent,
       agent_socket_send (cand->nicesock, &cand->server,
           stun_message_length (&cand->stun_message), (gchar *)cand->stun_buffer);
 
-      G_GNUC_FALLTHROUGH;
+      /* fall through */
     case STUN_USAGE_TIMER_RETURN_SUCCESS:
       agent_timeout_add_with_context (agent, &cand->tick_source,
           "TURN deallocate retransmission", stun_timer_remainder (&cand->timer),