Fix a few format string bugs found by Ilja van Sprundel.
svn path=/trunk/; revision=18677
This commit is contained in:
parent
1f4873db0b
commit
7976c442db
|
@ -12703,7 +12703,7 @@ dissect_ansi_param(ASN1_SCK *asn1, proto_tree *tree)
|
|||
|
||||
if (ansi_map_add_string[0] != '\0')
|
||||
{
|
||||
proto_item_append_text(item, ansi_map_add_string);
|
||||
proto_item_append_text(item, "%s", ansi_map_add_string);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -12766,7 +12766,7 @@ dissect_ansi_params(ASN1_SCK *asn1, proto_tree *tree)
|
|||
|
||||
if (ansi_map_add_string[0] != '\0')
|
||||
{
|
||||
proto_item_append_text(item, ansi_map_add_string);
|
||||
proto_item_append_text(item, "%s", ansi_map_add_string);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -13033,23 +13033,23 @@ dissect_ansi_map(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
add_itu_tcap_subdissector(ssn , ansi_map_handle);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
static void range_add_callback(guint32 ssn)
|
||||
{
|
||||
if (ssn) {
|
||||
add_ansi_tcap_subdissector(ssn , ansi_map_handle);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
void
|
||||
proto_reg_handoff_ansi_map(void)
|
||||
{
|
||||
static int ansi_map_prefs_initialized = FALSE;
|
||||
data_handle = find_dissector("data");
|
||||
|
||||
|
||||
if(!ansi_map_prefs_initialized)
|
||||
{
|
||||
ansi_map_prefs_initialized = TRUE;
|
||||
|
@ -13059,13 +13059,13 @@ dissect_ansi_map(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
{
|
||||
range_foreach(ssn_range, range_delete_callback);
|
||||
}
|
||||
|
||||
|
||||
g_free(ssn_range);
|
||||
ssn_range = range_copy(global_ssn_range);
|
||||
|
||||
|
||||
range_foreach(ssn_range, range_add_callback);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/* Register the protocol with Wireshark */
|
||||
|
@ -13198,7 +13198,7 @@ proto_register_ansi_map(void)
|
|||
|
||||
|
||||
ansi_map_module = prefs_register_protocol(proto_ansi_map, proto_reg_handoff_ansi_map);
|
||||
|
||||
|
||||
prefs_register_range_preference(ansi_map_module, "map.ssn", "GSM MAP SSNs",
|
||||
"GSM MAP SSNs to decode as ANSI MAP",
|
||||
&global_ssn_range, MAX_SSN);
|
||||
|
|
|
@ -63,7 +63,7 @@
|
|||
* 11.8.2003
|
||||
* Additional interpretation of field Chain Position.
|
||||
* Show the chain position in the interface list.
|
||||
* Support for new format of fw monitor file
|
||||
* Support for new format of fw monitor file
|
||||
* writen by option -u | -s for UUID/SUUID.
|
||||
* NOTICE: First paket will have UUID == 0 !
|
||||
*
|
||||
|
@ -139,7 +139,7 @@ dissect_fw1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
char *interface_name;
|
||||
guint32 iface_len = 10;
|
||||
guint16 etype;
|
||||
char *header;
|
||||
char *header;
|
||||
char *p_header;
|
||||
int i;
|
||||
gboolean found;
|
||||
|
@ -168,7 +168,7 @@ dissect_fw1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
|
||||
if (fw1_with_uuid)
|
||||
iface_len = 6;
|
||||
|
||||
|
||||
interface_name=ep_alloc(iface_len+1);
|
||||
tvb_get_nstringz0(tvb, 2, iface_len, interface_name);
|
||||
|
||||
|
@ -207,9 +207,9 @@ dissect_fw1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
if (tree) {
|
||||
if (!fw1_summary_in_tree)
|
||||
/* Do not show the summary in Protocol Tree */
|
||||
ti = proto_tree_add_protocol_format(tree, proto_fw1, tvb, 0, ETH_HEADER_SIZE, fw1_header);
|
||||
ti = proto_tree_add_protocol_format(tree, proto_fw1, tvb, 0, ETH_HEADER_SIZE, "%s", fw1_header);
|
||||
else
|
||||
ti = proto_tree_add_protocol_format(tree, proto_fw1, tvb, 0, ETH_HEADER_SIZE, header);
|
||||
ti = proto_tree_add_protocol_format(tree, proto_fw1, tvb, 0, ETH_HEADER_SIZE, "%s", header);
|
||||
|
||||
/* create display subtree for the protocol */
|
||||
fh_tree = proto_item_add_subtree(ti, ett_fw1);
|
||||
|
@ -220,8 +220,8 @@ dissect_fw1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
proto_tree_add_item(fh_tree, hf_fw1_chain, tvb, 1, 1, FALSE);
|
||||
|
||||
proto_tree_add_string_format(fh_tree, hf_fw1_interface, tvb, 2, iface_len, "Interface: %s", interface_name);
|
||||
|
||||
if (fw1_with_uuid)
|
||||
|
||||
if (fw1_with_uuid)
|
||||
proto_tree_add_item(fh_tree, hf_fw1_uuid, tvb, 8, 4, FALSE);
|
||||
}
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue