diff options
author | Evan Huus <eapache@gmail.com> | 2013-12-23 21:19:34 +0000 |
---|---|---|
committer | Evan Huus <eapache@gmail.com> | 2013-12-23 21:19:34 +0000 |
commit | e8057786921920130dbcaef548b0f366654694ff (patch) | |
tree | 8136281d8a4741d0aaecb850dc7709095e36ff99 /plugins/opcua | |
parent | a0321ddb9dc826a8c39f2609e893d3045dd3d165 (diff) | |
download | wireshark-e8057786921920130dbcaef548b0f366654694ff.tar.gz |
Avoid using ephemeral memory in register routines.
svn path=/trunk/; revision=54423
Diffstat (limited to 'plugins/opcua')
-rw-r--r-- | plugins/opcua/opcua.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/plugins/opcua/opcua.c b/plugins/opcua/opcua.c index 2e0d87003d..d76cd36652 100644 --- a/plugins/opcua/opcua.c +++ b/plugins/opcua/opcua.c @@ -129,6 +129,7 @@ static const char* g_szMessageTypes[] = */ void proto_register_opcua(void) { + char *tmp; static hf_register_info hf[] = { @@ -195,7 +196,9 @@ void proto_register_opcua(void) proto_register_subtree_array(ett, array_length(ett)); - range_convert_str(&global_tcp_ports_opcua, ep_strdup_printf("%u", OPCUA_PORT), 65535); + tmp = g_strdup_printf("%d", OPCUA_PORT); + range_convert_str(&global_tcp_ports_opcua, tmp, 65535); + g_free(tmp); reassembly_table_init(&opcua_reassembly_table, &addresses_reassembly_table_functions); |