aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-smpp.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2018-06-27 20:39:15 -0700
committerGuy Harris <guy@alum.mit.edu>2018-06-28 03:39:54 +0000
commit8304f69fd7f02cb5fe79010170c7550d441ad6e7 (patch)
tree5b95441afcd9ff732999054dffb13939e03cdce9 /epan/dissectors/packet-smpp.c
parentc8518753c8d3f7bb809d2615adc9f6f2e5e89530 (diff)
Add macros to initialize nstime_t values and use them.
This allows code to initialize them without having to know the details of the structure; the initializes should, and will, be changed if the members of the structure are changed. Change-Id: I93e6ebfcde9ceca17df696fcba4e8410c5afb175 Reviewed-on: https://code.wireshark.org/review/28501 Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan/dissectors/packet-smpp.c')
-rw-r--r--epan/dissectors/packet-smpp.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/epan/dissectors/packet-smpp.c b/epan/dissectors/packet-smpp.c
index 612e154bd2..04c5d9faed 100644
--- a/epan/dissectors/packet-smpp.c
+++ b/epan/dissectors/packet-smpp.c
@@ -1894,7 +1894,7 @@ submit_sm(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo,
const char *src_str = NULL;
const char *dst_str = NULL;
address save_src, save_dst;
- nstime_t zero_time = {0, 0};
+ nstime_t zero_time = NSTIME_INIT_ZERO;
smpp_handle_string_z(tree, tvb, hf_smpp_service_type, &offset, "(Default)");
smpp_handle_int1(tree, tvb, hf_smpp_source_addr_ton, &offset);
@@ -1970,7 +1970,7 @@ replace_sm(proto_tree *tree, tvbuff_t *tvb)
int offset = 0;
guint8 flag;
guint8 length;
- nstime_t zero_time = {0, 0};
+ nstime_t zero_time = NSTIME_INIT_ZERO;
smpp_handle_string(tree, tvb, hf_smpp_message_id, &offset);
smpp_handle_int1(tree, tvb, hf_smpp_source_addr_ton, &offset);
@@ -2022,7 +2022,7 @@ submit_multi(proto_tree *tree, tvbuff_t *tvb)
int offset = 0;
guint8 flag;
guint8 length;
- nstime_t zero_time = {0, 0};
+ nstime_t zero_time = NSTIME_INIT_ZERO;
smpp_handle_string_z(tree, tvb, hf_smpp_service_type, &offset, "(Default)");
smpp_handle_int1(tree, tvb, hf_smpp_source_addr_ton, &offset);
@@ -2120,7 +2120,7 @@ static void
broadcast_sm(proto_tree *tree, tvbuff_t *tvb)
{
int offset = 0;
- nstime_t zero_time = {0, 0};
+ nstime_t zero_time = NSTIME_INIT_ZERO;
smpp_handle_string_z(tree, tvb, hf_smpp_service_type, &offset, "(Default)");
smpp_handle_int1(tree, tvb, hf_smpp_source_addr_ton, &offset);