diff options
author | sahlberg <sahlberg@f5534014-38df-0310-8fa8-9805f1628bb7> | 2005-08-02 17:34:14 +0000 |
---|---|---|
committer | sahlberg <sahlberg@f5534014-38df-0310-8fa8-9805f1628bb7> | 2005-08-02 17:34:14 +0000 |
commit | 46eccff0f37b38d1be30f1cac34c75672eda3252 (patch) | |
tree | bba4add317224559c280b528ad4b6110e9a88cfd /epan/dissectors/packet-mmse.c | |
parent | 5c92eefa9b6e926625e0764107021bfa0383cb7a (diff) |
ememify the tvb_get_string call in mmse.
the strings mmse got from tvb_get_string were never released anyway
so this would resolve significant memory leakage in mmse.
there are still memleaks in mmse but one step at a time
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@15197 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'epan/dissectors/packet-mmse.c')
-rw-r--r-- | epan/dissectors/packet-mmse.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/epan/dissectors/packet-mmse.c b/epan/dissectors/packet-mmse.c index fcbb97a70a..142e5909ba 100644 --- a/epan/dissectors/packet-mmse.c +++ b/epan/dissectors/packet-mmse.c @@ -535,10 +535,10 @@ get_encoded_strval(tvbuff_t *tvb, guint offset, char **strval) if (field < 32) { length = get_value_length(tvb, offset, &count); if (length < 2) { - *strval = g_strdup(""); + *strval = ""; } else { /* \todo Something with "Char-set", skip for now */ - *strval = (char *)tvb_get_string(tvb, offset + count + 1, length - 1); + *strval = (char *)ep_tvb_get_string(tvb, offset + count + 1, length - 1); } return count + length; } else |