]> git.proxmox.com Git - ovs.git/commitdiff
ovn-nbctl: Fix 32-bit build with gcc.
authorIlya Maximets <i.maximets@samsung.com>
Wed, 17 Apr 2019 17:22:06 +0000 (20:22 +0300)
committerBen Pfaff <blp@ovn.org>
Wed, 17 Apr 2019 17:47:58 +0000 (10:47 -0700)
ovn/utilities/ovn-nbctl.c: In function 'print_routing_policy':
ovn/utilities/ovn-nbctl.c:3620:23: error: format '%ld' expects argument
    of type 'long int', but argument 3 has type 'int64_t'
                       policy->match, policy->action, next_hop);
                       ^
ovn/utilities/ovn-nbctl.c:3624:23: error: format '%ld' expects argument
    of type 'long int', but argument 3 has type 'int64_t'
                       policy->match, policy->action);
                       ^
ovn/utilities/ovn-nbctl.c: In function 'cmd_ha_ch_grp_list':
ovn/utilities/ovn-nbctl.c:5056:27: error: format '%lu' expects argument
    of type 'long unsigned int', but argument 10 has type 'int64_t'
                           ha_ch->priority);
                           ^
cc1: all warnings being treated as errors
make[2]: *** [ovn/utilities/ovn-nbctl.o] Error 1

https://travis-ci.org/openvswitch/ovs/jobs/521015912

CC: Numan Siddique <nusiddiq@redhat.com>
CC: Mary Manohar <mary.manohar@nutanix.com>
Fixes: 1be1e0e5e0d1 ("ovn: Add generic HA chassis group")
Fixes: a64bb573468f ("Policy-based routing (PBR) in OVN.")
Signed-off-by: Ilya Maximets <i.maximets@samsung.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
ovn/utilities/ovn-nbctl.c

index b7004b668fe4e466e2b8ed8a94cbe0f771f1b8a8..e86ab7f7ab733a6383ec89b372e0620b124f3d10 100644 (file)
@@ -3616,11 +3616,11 @@ print_routing_policy(const struct nbrec_logical_router_policy *policy,
 {
     if (policy->nexthop != NULL) {
         char *next_hop = normalize_prefix_str(policy->nexthop);
-        ds_put_format(s, "%10ld %50s %15s %25s", policy->priority,
+        ds_put_format(s, "%10"PRId64" %50s %15s %25s", policy->priority,
                       policy->match, policy->action, next_hop);
         free(next_hop);
     } else {
-        ds_put_format(s, "%10ld %50s %15s", policy->priority,
+        ds_put_format(s, "%10"PRId64" %50s %15s", policy->priority,
                       policy->match, policy->action);
     }
     ds_put_char(s, '\n');
@@ -5051,7 +5051,7 @@ cmd_ha_ch_grp_list(struct ctl_context *ctx)
             ha_ch = ha_ch_grp->ha_chassis[i];
             ds_put_format(&ctx->output,
                           "    "UUID_FMT " (%s)\n"
-                          "    priority %lu\n\n",
+                          "    priority %"PRId64"\n\n",
                           UUID_ARGS(&ha_ch->header_.uuid), ha_ch->chassis_name,
                           ha_ch->priority);
         }