diff options
author | etxrab <etxrab@f5534014-38df-0310-8fa8-9805f1628bb7> | 2011-11-19 17:21:35 +0000 |
---|---|---|
committer | etxrab <etxrab@f5534014-38df-0310-8fa8-9805f1628bb7> | 2011-11-19 17:21:35 +0000 |
commit | 93a8dcc5e29222c3c48ad706146cad165cb8695f (patch) | |
tree | f7af4cec7fbd887636937cf5edeb28192322b0be /epan/dissectors | |
parent | 6ccaa90c88f8adccd54e123dbd6629aba760f801 (diff) |
Fix Warnings.
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@39948 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'epan/dissectors')
-rw-r--r-- | epan/dissectors/packet-ansi_tcap.c | 12 | ||||
-rw-r--r-- | epan/dissectors/packet-sip.c | 18 |
2 files changed, 15 insertions, 15 deletions
diff --git a/epan/dissectors/packet-ansi_tcap.c b/epan/dissectors/packet-ansi_tcap.c index ce74925ae9..638ba765e3 100644 --- a/epan/dissectors/packet-ansi_tcap.c +++ b/epan/dissectors/packet-ansi_tcap.c @@ -258,15 +258,15 @@ static GHashTable *TransactionId_table=NULL; static void TransactionId_table_cleanup(gpointer key , gpointer value, gpointer user_data _U_){ - struct ansi_tcap_invokedata_t *ansi_tcap_saved_invokedata = value; - gchar *TransactionId_str = key; + struct ansi_tcap_invokedata_t *ansi_tcap_saved_invokedata = (struct ansi_tcap_invokedata_t *)value; + gchar *TransactionId_str = (gchar *)key; g_free(TransactionId_str); g_free(ansi_tcap_saved_invokedata); } -void +static void ansi_tcap_init_transaction_table(void){ /* Destroy any existing memory chunks / hashes. */ @@ -313,11 +313,11 @@ save_invoke_data(packet_info *pinfo, proto_tree *tree _U_, tvbuff_t *tvb _U_){ } /* If the entry allready exists don't owervrite it */ - ansi_tcap_saved_invokedata = g_hash_table_lookup(TransactionId_table,buf); + ansi_tcap_saved_invokedata = (struct ansi_tcap_invokedata_t *)g_hash_table_lookup(TransactionId_table,buf); if(ansi_tcap_saved_invokedata) return; - ansi_tcap_saved_invokedata = g_malloc(sizeof(struct ansi_tcap_invokedata_t)); + ansi_tcap_saved_invokedata = g_new(struct ansi_tcap_invokedata_t,1); ansi_tcap_saved_invokedata->OperationCode = ansi_tcap_private.d.OperationCode; ansi_tcap_saved_invokedata->OperationCode_national = ansi_tcap_private.d.OperationCode_national; ansi_tcap_saved_invokedata->OperationCode_private = ansi_tcap_private.d.OperationCode_private; @@ -361,7 +361,7 @@ find_saved_invokedata(packet_info *pinfo, proto_tree *tree _U_, tvbuff_t *tvb _U break; } - ansi_tcap_saved_invokedata = g_hash_table_lookup(TransactionId_table, buf); + ansi_tcap_saved_invokedata = (struct ansi_tcap_invokedata_t *)g_hash_table_lookup(TransactionId_table, buf); if(ansi_tcap_saved_invokedata){ ansi_tcap_private.d.OperationCode = ansi_tcap_saved_invokedata->OperationCode; ansi_tcap_private.d.OperationCode_national = ansi_tcap_saved_invokedata->OperationCode_national; diff --git a/epan/dissectors/packet-sip.c b/epan/dissectors/packet-sip.c index c06a6065c0..588c022c18 100644 --- a/epan/dissectors/packet-sip.c +++ b/epan/dissectors/packet-sip.c @@ -888,8 +888,8 @@ typedef struct /* Equal keys */ static gint sip_equal(gconstpointer v, gconstpointer v2) { - const sip_hash_key* val1 = v; - const sip_hash_key* val2 = v2; + const sip_hash_key* val1 = (sip_hash_key*)v; + const sip_hash_key* val2 = (sip_hash_key*)v2; /* Call id must match */ if (strcmp(val1->call_id, val2->call_id) != 0) @@ -1680,7 +1680,7 @@ dissect_sip_reason_header(tvbuff_t *tvb, proto_tree *tree, gint start_offset, gi } /* Dissect the details of a Route (and Record-Route) header */ -static void dissect_sip_route_header(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, hf_sip_uri_t *sip_route_uri, gint start_offset, gint line_end_offset) +static void dissect_sip_route_header(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, hf_sip_uri_t *sip_route_uri_p, gint start_offset, gint line_end_offset) { gint current_offset; guchar c; @@ -1703,7 +1703,7 @@ static void dissect_sip_route_header(tvbuff_t *tvb, proto_tree *tree, packet_inf current_offset = dissect_sip_name_addr_or_addr_spec(tvb, pinfo, start_offset, current_offset, &uri_offsets); if(current_offset == -1) return; - display_sip_uri(tvb, tree, &uri_offsets, sip_route_uri); + display_sip_uri(tvb, tree, &uri_offsets, sip_route_uri_p); current_offset++; start_offset = current_offset + 1; @@ -1713,7 +1713,7 @@ static void dissect_sip_route_header(tvbuff_t *tvb, proto_tree *tree, packet_inf current_offset = dissect_sip_name_addr_or_addr_spec(tvb, pinfo, start_offset, line_end_offset, &uri_offsets); if(current_offset == -1) return; - display_sip_uri(tvb, tree, &uri_offsets, sip_route_uri); + display_sip_uri(tvb, tree, &uri_offsets, sip_route_uri_p); return; } @@ -3412,7 +3412,7 @@ static gint sip_is_known_sip_header(gchar *header_name, guint header_len) /* Compact name is one character long */ if(header_len>1){ - pos = GPOINTER_TO_INT(g_hash_table_lookup(sip_headers_hash, header_name)); + pos = GPOINTER_TO_UINT(g_hash_table_lookup(sip_headers_hash, header_name)); if (pos!=0) return pos; } @@ -3647,7 +3647,7 @@ guint sip_is_packet_resend(packet_info *pinfo, break; } - sip_frame_result = p_get_proto_data(pinfo->fd, proto_sip); + sip_frame_result = (sip_frame_result_value *)p_get_proto_data(pinfo->fd, proto_sip); if (sip_frame_result == NULL) { sip_frame_result = se_alloc0(sizeof(sip_frame_result_value)); @@ -3750,7 +3750,7 @@ guint sip_find_request(packet_info *pinfo, /* Store return value with this packet */ - sip_frame_result = p_get_proto_data(pinfo->fd, proto_sip); + sip_frame_result = (sip_frame_result_value *)p_get_proto_data(pinfo->fd, proto_sip); if (sip_frame_result == NULL) { /* Allocate and set all values to zero */ @@ -3870,7 +3870,7 @@ guint sip_find_invite(packet_info *pinfo, result = p_val->frame_number; /* Store return value with this packet */ - sip_frame_result = p_get_proto_data(pinfo->fd, proto_sip); + sip_frame_result = (sip_frame_result_value *)p_get_proto_data(pinfo->fd, proto_sip); if (sip_frame_result == NULL) { /* Allocate and set all values to zero */ |