diff options
author | João Valverde <joao.valverde@tecnico.ulisboa.pt> | 2021-05-24 00:46:43 +0100 |
---|---|---|
committer | Wireshark GitLab Utility <gerald+gitlab-utility@wireshark.org> | 2021-06-06 20:05:26 +0000 |
commit | 4aff36d501400552d7df59473db17ef7add8b11c (patch) | |
tree | 05518b1962382e2c4edf5935e9c4284747a0b302 /wiretap/pppdump.c | |
parent | ef0f022f8629009daf7c31e204b9d65b1805f6e4 (diff) |
Replace g_assert() with ws_assert() in places
Diffstat (limited to 'wiretap/pppdump.c')
-rw-r--r-- | wiretap/pppdump.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/wiretap/pppdump.c b/wiretap/pppdump.c index 68799df933..7c72ccf74f 100644 --- a/wiretap/pppdump.c +++ b/wiretap/pppdump.c @@ -14,6 +14,8 @@ #include <errno.h> #include <string.h> +#include <wsutil/ws_assert.h> + /* pppdump records Daniel Thompson (STMicroelectronics) <daniel.thompson@st.com> @@ -457,7 +459,7 @@ process_data(pppdump_t *state, FILE_T fh, pkt_t *pkt, int n, guint8 *pd, pid->offset = pkt->id_offset; pid->num_bytes_to_skip = pkt->sd_offset - pkt->id_offset - 3; - g_assert(pid->num_bytes_to_skip >= 0); + ws_assert(pid->num_bytes_to_skip >= 0); } num_bytes--; @@ -557,7 +559,7 @@ collate(pppdump_t* state, FILE_T fh, int *err, gchar **err_info, guint8 *pd, * sequential processing. */ if (state->num_bytes > 0) { - g_assert(num_bytes_to_skip == 0); + ws_assert(num_bytes_to_skip == 0); pkt = state->pkt; num_written = process_data(state, fh, pkt, state->num_bytes, pd, err, err_info, pid); @@ -631,7 +633,7 @@ collate(pppdump_t* state, FILE_T fh, int *err, gchar **err_info, guint8 *pd, if (n == 0) continue; - g_assert(num_bytes_to_skip < n); + ws_assert(num_bytes_to_skip < n); while (num_bytes_to_skip) { if (file_getc(fh) == EOF) goto done; |