diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-09-19 04:14:26 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-09-19 04:14:26 +0000 |
commit | c4e8a3222648fcf22ca207f1815ebbf7cd144eeb (patch) | |
tree | 93d5c6aa93d9987680dd1adad5685e2ad698f223 /epan/dissectors/asn1/sv/sv.cnf | |
parent | Adding upstream version 4.2.6. (diff) | |
download | wireshark-upstream.tar.xz wireshark-upstream.zip |
Adding upstream version 4.4.0.upstream/4.4.0upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'epan/dissectors/asn1/sv/sv.cnf')
-rw-r--r-- | epan/dissectors/asn1/sv/sv.cnf | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/epan/dissectors/asn1/sv/sv.cnf b/epan/dissectors/asn1/sv/sv.cnf index 7da1f370..fd2634e0 100644 --- a/epan/dissectors/asn1/sv/sv.cnf +++ b/epan/dissectors/asn1/sv/sv.cnf @@ -15,18 +15,18 @@ SampledValues #.FIELD_RENAME #.FN_BODY ASDU/smpCnt VAL_PTR = &value - guint32 value; + uint32_t value; %(DEFAULT_BODY)s sv_data.smpCnt = value; #.END #.FN_BODY UtcTime - guint32 len; - guint32 seconds; - guint32 fraction; - guint32 nanoseconds; + uint32_t len; + uint32_t seconds; + uint32_t fraction; + uint32_t nanoseconds; nstime_t ts; - gchar * ptime; + char * ptime; len = tvb_reported_length_remaining(tvb, offset); @@ -34,7 +34,7 @@ SampledValues { proto_tree_add_expert_format(tree, actx->pinfo, &ei_sv_mal_utctime, tvb, offset, len, "BER Error: malformed UTCTime encoding, length must be 8 bytes"); - if(hf_index >= 0) + if(hf_index > 0) { proto_tree_add_string(tree, hf_index, tvb, offset, len, "????"); } @@ -43,14 +43,14 @@ SampledValues seconds = tvb_get_ntohl(tvb, offset); fraction = tvb_get_ntoh24(tvb, offset+4) * 0x100; /* Only 3 bytes are recommended */ - nanoseconds = (guint32)( ((guint64)fraction * G_GUINT64_CONSTANT(1000000000)) / G_GUINT64_CONSTANT(0x100000000) ) ; + nanoseconds = (uint32_t)( ((uint64_t)fraction * UINT64_C(1000000000)) / UINT64_C(0x100000000) ) ; ts.secs = seconds; ts.nsecs = nanoseconds; - ptime = abs_time_to_str(actx->pinfo->pool, &ts, ABSOLUTE_TIME_UTC, TRUE); + ptime = abs_time_to_str(actx->pinfo->pool, &ts, ABSOLUTE_TIME_UTC, true); - if(hf_index >= 0) + if(hf_index > 0) { proto_tree_add_string(tree, hf_index, tvb, offset, len, ptime); } @@ -61,13 +61,13 @@ SampledValues UtcTime TYPE = FT_STRING DISPLAY = BASE_NONE #.FN_BODY ASDU/smpSynch VAL_PTR = &value - guint32 value; + uint32_t value; %(DEFAULT_BODY)s sv_data.smpSynch = value; #.END #.FN_BODY ASDU/smpMod VAL_PTR = &value - guint32 value; + uint32_t value; %(DEFAULT_BODY)s sv_data.smpMod = value; #.END @@ -81,10 +81,10 @@ UtcTime TYPE = FT_STRING DISPLAY = BASE_NONE #.END #.FN_BODY GmidData - guint32 len; + uint32_t len; proto_item *gmidentity_ti; proto_tree *gmidentity_tree; - const gchar *manuf_name; + const char *manuf_name; len = tvb_reported_length_remaining(tvb, offset); @@ -92,7 +92,7 @@ UtcTime TYPE = FT_STRING DISPLAY = BASE_NONE { proto_tree_add_expert_format(tree, actx->pinfo, &ei_sv_mal_gmidentity, tvb, offset, len, "BER Error: malformed gmIdentity encoding, length must be 8 bytes"); - if(hf_index >= 0) + if(hf_index > 0) { proto_tree_add_string(tree, hf_index, tvb, offset, len, "????"); } |