summaryrefslogtreecommitdiff
path: root/socket
diff options
context:
space:
mode:
authorOlivier CrĂȘte <olivier.crete@collabora.com>2021-11-01 22:22:32 -0400
committerOlivier CrĂȘte <olivier.crete@collabora.com>2021-11-01 22:22:32 -0400
commit69c2015cb549ab14d6aac686e0c6e11f55b1664b (patch)
treecbc2767ed102f07d10f68643c154d24bf837d9dd /socket
parent01e2de64af2f6bb94c5d6c81b22b817fb6933bf1 (diff)
downloadlibnice-69c2015cb549ab14d6aac686e0c6e11f55b1664b.tar.gz
Remove g_assert_cmp* macros outside of the unit tests
Diffstat (limited to 'socket')
-rw-r--r--socket/http.c2
-rw-r--r--socket/socket.c2
-rw-r--r--socket/udp-turn.c8
3 files changed, 6 insertions, 6 deletions
diff --git a/socket/http.c b/socket/http.c
index 23277f3..96ddfd8 100644
--- a/socket/http.c
+++ b/socket/http.c
@@ -203,7 +203,7 @@ socket_close (NiceSocket *sock)
static void
assert_ring_buffer_valid (HttpPriv *priv)
{
- g_assert_cmpint (priv->recv_buf_fill, <=, priv->recv_buf_length);
+ g_assert (priv->recv_buf_fill <= priv->recv_buf_length);
g_assert (priv->recv_buf_pos == 0 ||
priv->recv_buf_pos < priv->recv_buf_length);
g_assert (priv->recv_buf_length == 0 || priv->recv_buf != NULL);
diff --git a/socket/socket.c b/socket/socket.c
index 860feea..b60d2d3 100644
--- a/socket/socket.c
+++ b/socket/socket.c
@@ -333,7 +333,7 @@ nice_socket_queue_send (GQueue *send_queue, const NiceAddress *to,
offset += len;
}
- g_assert_cmpint (offset, ==, tbs->length);
+ g_assert (offset == tbs->length);
}
}
diff --git a/socket/udp-turn.c b/socket/udp-turn.c
index 3c2e718..1e86a0a 100644
--- a/socket/udp-turn.c
+++ b/socket/udp-turn.c
@@ -671,10 +671,10 @@ _socket_send_messages_wrapped (NiceSocket *sock, const NiceAddress *to,
guint i;
gint ret;
- g_assert_cmpuint (n_messages, ==, 1);
+ g_assert (n_messages == 1);
message = &messages[0];
message_len = output_message_get_size (message);
- g_assert_cmpint (message_len, <=, G_MAXUINT16);
+ g_assert (message_len <= G_MAXUINT16);
/* ICE-TCP requires that all packets be framed with RFC4571 */
@@ -1246,7 +1246,7 @@ nice_udp_turn_socket_cache_realm_nonce_locked (NiceSocket *sock,
UdpTurnPriv *priv = sock->priv;
gconstpointer tmp;
- g_assert_cmpint (sock->type, ==, NICE_SOCKET_TYPE_UDP_TURN);
+ g_assert (sock->type == NICE_SOCKET_TYPE_UDP_TURN);
g_free (priv->cached_realm);
priv->cached_realm = NULL;
@@ -1293,7 +1293,7 @@ nice_udp_turn_socket_parse_recv_message (NiceSocket *sock, NiceSocket **from_soc
message->from, message->length, message->buffers[0].buffer,
message->from, message->buffers[0].buffer, message->length);
- g_assert_cmpuint (len, <=, message->length);
+ g_assert (len <= message->length);
message->length = len;