diff --git a/controller/ovn-controller.c b/controller/ovn-controller.c index cbf4af069b..fba41ce3a4 100644 --- a/controller/ovn-controller.c +++ b/controller/ovn-controller.c @@ -4556,7 +4556,7 @@ int main(int argc, char *argv[]) { struct unixctl_server *unixctl; - struct ovn_exit_args exit_args = {}; + struct ovn_exit_args exit_args = {0}; int retval; /* Read from system-id-override file once on startup. */ diff --git a/controller/pinctrl.c b/controller/pinctrl.c index ff143b0340..9a852b94cd 100644 --- a/controller/pinctrl.c +++ b/controller/pinctrl.c @@ -1298,7 +1298,7 @@ fill_ipv6_prefix_state(struct ovsdb_idl_txn *ovnsb_idl_txn, pfd->prefix = in6addr_any; } } else if (pfd->state == PREFIX_PENDING && ovnsb_idl_txn) { - char prefix_str[INET6_ADDRSTRLEN + 1] = {}; + char prefix_str[INET6_ADDRSTRLEN + 1] = {0}; if (!ipv6_string_mapped(prefix_str, &pfd->prefix)) { goto out; } @@ -3850,7 +3850,7 @@ packet_put_ra_dnssl_opt(struct dp_packet *b, ovs_be32 lifetime, char *dnssl_data) { size_t prev_l4_size = dp_packet_l4_size(b); - char dnssl[255] = {}; + char dnssl[255] = {0}; int size; size = encode_ra_dnssl_opt(dnssl_data, dnssl, sizeof(dnssl)); diff --git a/lib/actions.c b/lib/actions.c index c7a07db8e2..3527ad8c5a 100644 --- a/lib/actions.c +++ b/lib/actions.c @@ -3432,7 +3432,7 @@ encode_put_nd_ra_option(const struct ovnact_gen_option *o, case ND_OPT_DNSSL: { - char dnssl[255] = {}; + char dnssl[255] = {0}; int size; size = encode_ra_dnssl_opt(c->string, dnssl, sizeof(dnssl)); @@ -4931,7 +4931,7 @@ format_COMMIT_LB_AFF(const struct ovnact_commit_lb_aff *lb_aff, struct ds *s) bool ipv6 = !IN6_IS_ADDR_V4MAPPED(&lb_aff->vip); if (ipv6) { - char ip_str[INET6_ADDRSTRLEN] = {}; + char ip_str[INET6_ADDRSTRLEN] = {0}; inet_ntop(AF_INET6, &lb_aff->vip, ip_str, INET6_ADDRSTRLEN); ds_put_format(s, "commit_lb_aff(vip = \"[%s]", ip_str); } else { @@ -4946,7 +4946,7 @@ format_COMMIT_LB_AFF(const struct ovnact_commit_lb_aff *lb_aff, struct ds *s) ds_put_cstr(s, "\""); if (ipv6) { - char ip_str[INET6_ADDRSTRLEN] = {}; + char ip_str[INET6_ADDRSTRLEN] = {0}; inet_ntop(AF_INET6, &lb_aff->backend, ip_str, INET6_ADDRSTRLEN); ds_put_format(s, ", backend = \"[%s]", ip_str); } else { diff --git a/northd/ovn-northd.c b/northd/ovn-northd.c index a551d88cde..d52951dc16 100644 --- a/northd/ovn-northd.c +++ b/northd/ovn-northd.c @@ -764,7 +764,7 @@ main(int argc, char *argv[]) int res = EXIT_SUCCESS; struct unixctl_server *unixctl; int retval; - struct ovn_exit_args exit_args = {}; + struct ovn_exit_args exit_args = {0}; int n_threads = 1; struct northd_state state = { .had_lock = false,