aboutsummaryrefslogtreecommitdiffstats
path: root/extcap.c
diff options
context:
space:
mode:
authorStig Bjørlykke <stig@bjorlykke.org>2016-12-14 13:43:27 +0100
committerDario Lombardo <lomato@gmail.com>2016-12-14 14:35:30 +0000
commit07ffcf90426b05082e95b71268181f108fc7403b (patch)
tree761c65c9be29610c51a2382d41022c598286c3f9 /extcap.c
parent978a30bd23d37b580afa642ce1b262b3dbd2e899 (diff)
extcap: Avoid double free of help.
Avoid double free of help when having multiple extcap interfaces. Ping-Bug: 13218 Change-Id: I6a0d6afd645787f9814c02e84079b4e8763d05f1 Reviewed-on: https://code.wireshark.org/review/19261 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Reviewed-by: Dario Lombardo <lomato@gmail.com>
Diffstat (limited to 'extcap.c')
-rw-r--r--extcap.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/extcap.c b/extcap.c
index 973d2a9d2c..87a584d98a 100644
--- a/extcap.c
+++ b/extcap.c
@@ -385,7 +385,7 @@ static gboolean interfaces_cb(const gchar *extcap, const gchar *ifname _U_, gcha
else if (int_iter->if_type == EXTCAP_SENTENCE_EXTCAP)
{
g_log(LOG_DOMAIN_CAPTURE, G_LOG_LEVEL_DEBUG, " Extcap [%s] ", int_iter->call);
- help = g_strdup(int_iter->help);
+ help = int_iter->help;
}
if (int_iter->if_type == EXTCAP_SENTENCE_INTERFACE)
@@ -403,7 +403,7 @@ static gboolean interfaces_cb(const gchar *extcap, const gchar *ifname _U_, gcha
}
int_iter->extcap_path = g_strdup(extcap);
- int_iter->help = help;
+ int_iter->help = g_strdup(help);
preserve_interface = extcap_if_add(int_iter);
}