diff options
author | Dario Lombardo <lomato@gmail.com> | 2018-02-18 18:42:31 +0100 |
---|---|---|
committer | Jakub Zawadzki <darkjames-ws@darkjames.pl> | 2018-02-21 21:51:12 +0000 |
commit | 95e33c7097fb5c858e1fc34ee9e92c15b788c0db (patch) | |
tree | 0185c32043ef6444850c5f4e77d16cba4e736fbf /epan | |
parent | 7802bbb09163e3a91cf68e2ba9ef03dc18c99372 (diff) |
dof: use g_malloc0 to prevent uninitialized memory (found by clang).
Change-Id: Iac8b077e7223668b58158a29628748aae85ed73e
Reviewed-on: https://code.wireshark.org/review/25885
Petri-Dish: Dario Lombardo <lomato@gmail.com>
Tested-by: Petri Dish Buildbot
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Jakub Zawadzki <darkjames-ws@darkjames.pl>
Diffstat (limited to 'epan')
-rw-r--r-- | epan/dissectors/packet-dof.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/epan/dissectors/packet-dof.c b/epan/dissectors/packet-dof.c index af4966113e..402ef95c0f 100644 --- a/epan/dissectors/packet-dof.c +++ b/epan/dissectors/packet-dof.c @@ -7865,7 +7865,7 @@ static int dissect_ccm(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void const guint8 *epp_buf = tvb_get_ptr(tvb, 0, -1); guint a_len = offset; guint16 e_off; - guint8 *buf = (guint8 *)g_malloc(e_len); + guint8 *buf = (guint8 *)g_malloc0(e_len); tvbuff_t *app; /* The default nonce is a function of whether or not this is the server |