aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-fw1.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2012-08-14 17:58:41 +0000
committerMichael Mann <mmann78@netscape.net>2012-08-14 17:58:41 +0000
commit5dd7371960f02a33d50faf2f7202792c1da9a042 (patch)
tree1ac87d0599ef4502e570979022e1f8db4ddacf95 /epan/dissectors/packet-fw1.c
parentc8a48320502996cd41f893ff74e9fa091aa2ff3e (diff)
more ephemeral memory cleanup
svn path=/trunk/; revision=44496
Diffstat (limited to 'epan/dissectors/packet-fw1.c')
-rw-r--r--epan/dissectors/packet-fw1.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/epan/dissectors/packet-fw1.c b/epan/dissectors/packet-fw1.c
index 4d9d180a5d..022f280d8b 100644
--- a/epan/dissectors/packet-fw1.c
+++ b/epan/dissectors/packet-fw1.c
@@ -114,17 +114,12 @@ static gint ett_fw1 = -1;
#define ETH_HEADER_SIZE 14
#define MAX_INTERFACES 20
-static char *p_interfaces[MAX_INTERFACES];
+static gchar *p_interfaces[MAX_INTERFACES];
static int interface_anzahl=0;
static void
fw1_init(void)
{
- int i;
-
- for (i=0; i<interface_anzahl; i++) {
- g_free(p_interfaces[i]);
- }
interface_anzahl = 0;
}
@@ -176,7 +171,7 @@ dissect_fw1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
}
}
if (!found && interface_anzahl < MAX_INTERFACES) {
- p_interfaces[interface_anzahl] = g_strdup(interface_name);
+ p_interfaces[interface_anzahl] = se_strdup(interface_name);
interface_anzahl++;
}
@@ -278,7 +273,7 @@ proto_register_fw1(void)
register_dissector("fw1", dissect_fw1, proto_fw1);
- for (i=0; i<interface_anzahl; i++) {
+ for (i=0; i<MAX_INTERFACES; i++) {
p_interfaces[i] = NULL;
}
register_init_routine(fw1_init);