diff options
author | Evan Huus <eapache@gmail.com> | 2014-01-23 01:48:13 +0000 |
---|---|---|
committer | Evan Huus <eapache@gmail.com> | 2014-01-23 01:48:13 +0000 |
commit | 732db281e9da1a3009cf191a7705a766dfd397bf (patch) | |
tree | b345451ae04bcac658e3ad5d2110be771e5d5621 /epan/dissectors/packet-sip.c | |
parent | 6dcce1fb9b5b6302e5f062648d6e80fb82d3fe5e (diff) |
Use wmem_new0 to ensure that all field values are initialized. Caught by
valgrind fuzzing.
svn path=/trunk/; revision=54922
Diffstat (limited to 'epan/dissectors/packet-sip.c')
-rw-r--r-- | epan/dissectors/packet-sip.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/epan/dissectors/packet-sip.c b/epan/dissectors/packet-sip.c index 510e926648..7255367e3f 100644 --- a/epan/dissectors/packet-sip.c +++ b/epan/dissectors/packet-sip.c @@ -3701,7 +3701,7 @@ guint sip_is_packet_resend(packet_info *pinfo, /* Allocate a new key and value */ p_key = wmem_new(wmem_file_scope(), sip_hash_key); - p_val = wmem_new(wmem_file_scope(), sip_hash_value); + p_val = wmem_new0(wmem_file_scope(), sip_hash_value); /* Fill in key and value details */ g_snprintf(p_key->call_id, MAX_CALL_ID_SIZE, "%s", call_id); @@ -3717,7 +3717,6 @@ guint sip_is_packet_resend(packet_info *pinfo, p_val->cseq = cseq_number; g_strlcpy(p_val->method, cseq_method, MAX_CSEQ_METHOD_SIZE); p_val->transaction_state = nothing_seen; - p_val->frame_number = 0; if (line_type == REQUEST_LINE) { p_val->request_time = pinfo->fd->abs_ts; |