X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;ds=sidebyside;f=utilities%2Fovs-vsctl.c;h=84db728bcd7291c33737fcc11e1d67d6b85e01ce;hb=204bad294027fef6315b18b963d074139b3dfc52;hp=9baca4286205116a0247d7f898fa849c34c5cb1e;hpb=bb1c67c813c9bd80c2bd9acf2bf5158b48841c61;p=openvswitch diff --git a/utilities/ovs-vsctl.c b/utilities/ovs-vsctl.c index 9baca428..84db728b 100644 --- a/utilities/ovs-vsctl.c +++ b/utilities/ovs-vsctl.c @@ -824,7 +824,7 @@ ovs_delete_bridge(const struct ovsrec_open_vswitch *ovs, } static void -cmd_init(struct vsctl_context *ctx UNUSED) +cmd_init(struct vsctl_context *ctx OVS_UNUSED) { } @@ -832,10 +832,9 @@ static void cmd_add_br(struct vsctl_context *ctx) { bool may_exist = shash_find(&ctx->options, "--may-exist") != 0; - const char *br_name = ctx->argv[1]; - const char *parent_name = ctx->argc > 2 ? ctx->argv[2] : NULL; - int vlan = ctx->argc > 3 ? atoi(ctx->argv[3]) : 0; + const char *br_name, *parent_name; struct vsctl_info info; + int vlan; br_name = ctx->argv[1]; if (ctx->argc == 2) {