From 5a43799a17572c9a9962dc76fd681a14bb7689de Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Tue, 29 May 2007 18:52:42 +0000 Subject: Use G_GINT64_MODIFIER, rather than the PRI[douxX]64 macros, for GLib routines and routines using those routines. GLib might use different modifiers for 64-bit quantities than the platform's C library does. svn path=/trunk/; revision=21990 --- plugins/giop/packet-parlay.c | 22 +++++++++++----------- plugins/profinet/packet-pn-ptcp.c | 8 ++++---- plugins/rtnet/packet-rtnet.c | 4 ++-- 3 files changed, 17 insertions(+), 17 deletions(-) (limited to 'plugins') diff --git a/plugins/giop/packet-parlay.c b/plugins/giop/packet-parlay.c index a77111faba..7937003062 100644 --- a/plugins/giop/packet-parlay.c +++ b/plugins/giop/packet-parlay.c @@ -74632,7 +74632,7 @@ static void decode_org_csapi_pam_access_IpPAMIdentityPresence_setIdentityPresenc s_octet8 = get_CDR_long_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"expiresIn = %" PRId64,s_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"expiresIn = %" G_GINT64_MODIFIER "d",s_octet8); } u_octet4_loop_authToken = get_CDR_ulong(tvb, offset, stream_is_big_endian, boundary); @@ -75125,7 +75125,7 @@ static void decode_org_csapi_pam_access_IpPAMAgentPresence_setAgentPresenceExpir s_octet8 = get_CDR_long_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"expiresIn = %" PRId64,s_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"expiresIn = %" G_GINT64_MODIFIER "d",s_octet8); } u_octet4_loop_authToken = get_CDR_ulong(tvb, offset, stream_is_big_endian, boundary); @@ -75249,7 +75249,7 @@ static void decode_org_csapi_pam_access_IpPAMAgentPresence_setCapabilityPresence s_octet8 = get_CDR_long_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"expiresIn = %" PRId64,s_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"expiresIn = %" G_GINT64_MODIFIER "d",s_octet8); } u_octet4_loop_authToken = get_CDR_ulong(tvb, offset, stream_is_big_endian, boundary); @@ -93288,7 +93288,7 @@ static void decode_org_csapi_pam_TpPAMAttribute_st(tvbuff_t *tvb _U_, packet_inf s_octet8 = get_CDR_long_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMAttribute_ExpiresIn = %" PRId64,s_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMAttribute_ExpiresIn = %" G_GINT64_MODIFIER "d",s_octet8); } } @@ -94488,7 +94488,7 @@ static void decode_org_csapi_pam_TpPAMACPSEventData_st(tvbuff_t *tvb _U_, packet s_octet8 = get_CDR_long_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMACPSEventData_ReportingPeriod = %" PRId64,s_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMACPSEventData_ReportingPeriod = %" G_GINT64_MODIFIER "d",s_octet8); } } @@ -94628,7 +94628,7 @@ static void decode_org_csapi_pam_TpPAMAPSEventData_st(tvbuff_t *tvb _U_, packet_ s_octet8 = get_CDR_long_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMAPSEventData_ReportingPeriod = %" PRId64,s_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMAPSEventData_ReportingPeriod = %" G_GINT64_MODIFIER "d",s_octet8); } } @@ -94759,7 +94759,7 @@ static void decode_org_csapi_pam_TpPAMIPSEventData_st(tvbuff_t *tvb _U_, packet_ s_octet8 = get_CDR_long_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMIPSEventData_ReportingPeriod = %" PRId64,s_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMIPSEventData_ReportingPeriod = %" G_GINT64_MODIFIER "d",s_octet8); } } @@ -94908,7 +94908,7 @@ static void decode_org_csapi_pam_TpPAMAVCEventData_st(tvbuff_t *tvb _U_, packet_ s_octet8 = get_CDR_long_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMAVCEventData_ReportingPeriod = %" PRId64,s_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMAVCEventData_ReportingPeriod = %" G_GINT64_MODIFIER "d",s_octet8); } } @@ -95035,7 +95035,7 @@ static void decode_org_csapi_pam_TpPAMWCEventData_st(tvbuff_t *tvb _U_, packet_i s_octet8 = get_CDR_long_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMWCEventData_ReportingPeriod = %" PRId64,s_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"TpPAMWCEventData_ReportingPeriod = %" G_GINT64_MODIFIER "d",s_octet8); } } @@ -96147,7 +96147,7 @@ static void decode_org_csapi_TpSimpleAttributeValue_un(tvbuff_t *tvb _U_, packet s_octet8 = get_CDR_long_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"Int64Value = %" PRId64,s_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"Int64Value = %" G_GINT64_MODIFIER "d",s_octet8); } return; /* End Compare for this discriminant type */ @@ -96157,7 +96157,7 @@ static void decode_org_csapi_TpSimpleAttributeValue_un(tvbuff_t *tvb _U_, packet u_octet8 = get_CDR_ulong_long(tvb,offset,stream_is_big_endian, boundary); if (tree) { - proto_tree_add_text(tree,tvb,*offset-8,8,"UnsignedInt64Value = %" PRIu64,u_octet8); + proto_tree_add_text(tree,tvb,*offset-8,8,"UnsignedInt64Value = %" G_GINT64_MODIFIER "u",u_octet8); } return; /* End Compare for this discriminant type */ diff --git a/plugins/profinet/packet-pn-ptcp.c b/plugins/profinet/packet-pn-ptcp.c index 4b5b4f92f8..a1a597da67 100644 --- a/plugins/profinet/packet-pn-ptcp.c +++ b/plugins/profinet/packet-pn-ptcp.c @@ -586,19 +586,19 @@ dissect_PNPTCP_Header(tvbuff_t *tvb, int offset, delayms = (guint32) (delayns / (1000 * 1000)); if (check_col(pinfo->cinfo, COL_INFO)) - col_append_fstr(pinfo->cinfo, COL_INFO, ", Delay=%11" PRIu64 "ns", + col_append_fstr(pinfo->cinfo, COL_INFO, ", Delay=%11" G_GINT64_MODIFIER "uns", delayns); - proto_item_append_text(item, ", Delay=%" PRIu64 "ns", delayns); + proto_item_append_text(item, ", Delay=%" G_GINT64_MODIFIER "uns", delayns); if(delayns != 0) { - proto_item_append_text(header_item, ", Delay=%" PRIu64 "ns (%u.%03u,%03u,%03u sec)", + proto_item_append_text(header_item, ", Delay=%" G_GINT64_MODIFIER "uns (%u.%03u,%03u,%03u sec)", delayns, delayms / 1000, delayms % 1000, (delay10ns % (1000*100)) / 100, delay10ns % 100 * 10 + delay1ns); } else { - proto_item_append_text(header_item, ", Delay=%" PRIu64 "ns", + proto_item_append_text(header_item, ", Delay=%" G_GINT64_MODIFIER "uns", delayns); } } diff --git a/plugins/rtnet/packet-rtnet.c b/plugins/rtnet/packet-rtnet.c index 5801752e95..b5b457672b 100644 --- a/plugins/rtnet/packet-rtnet.c +++ b/plugins/rtnet/packet-rtnet.c @@ -479,7 +479,7 @@ dissect_tdma_sync(tvbuff_t *tvb, guint offset, proto_tree *tree) { ti = proto_tree_add_item(tree, hf_tdma_sync_xmit_stamp, tvb, offset, 8, FALSE); time = tvb_get_ntoh64(tvb, offset) - tvb_get_ntoh64(tvb, offset+8); - proto_item_append_text(ti, " (%s%" PRId64 ")", (time > 0) ? "+" : "", time); + proto_item_append_text(ti, " (%s%" G_GINT64_MODIFIER "d)", (time > 0) ? "+" : "", time); offset += 8; proto_tree_add_item(tree, hf_tdma_sync_sched_xmit, tvb, offset, 8, FALSE); @@ -511,7 +511,7 @@ dissect_tdma_reply_cal(tvbuff_t *tvb, guint offset, proto_tree *tree) { offset += 8; ti = proto_tree_add_item(tree, hf_tdma_rpl_cal_xmit_stamp, tvb, offset, 8, FALSE); - proto_item_append_text(ti, " (%s%" PRId64 ")", (time > 0) ? "+" : "", time); + proto_item_append_text(ti, " (%s%" G_GINT64_MODIFIER "d)", (time > 0) ? "+" : "", time); } static void -- cgit v1.2.3