summaryrefslogtreecommitdiff
path: root/utilities
diff options
context:
space:
mode:
authorBen Pfaff <blp@nicira.com>2011-03-04 12:46:37 -0800
committerBen Pfaff <blp@nicira.com>2011-03-04 12:49:41 -0800
commit25608d9720000ba2f4b4a881ca2a8cf519404f96 (patch)
treeead4b762aa9b65c74fc28a3c664f2695e694648a /utilities
parent55eccb868b8f1da858a9f724335b5bb059276497 (diff)
downloadopenvswitch-25608d9720000ba2f4b4a881ca2a8cf519404f96.tar.gz
ovs-dpctl: Support more than one option for "add-if" command.
This "while" loop in do_add_if() is supposed to split up everything after the interface name with ',' as the delimiter, but it didn't do that correctly. Also corrects a typo in the manpage pointed out by Justin Pettit.
Diffstat (limited to 'utilities')
-rw-r--r--utilities/ovs-dpctl.8.in2
-rw-r--r--utilities/ovs-dpctl.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/utilities/ovs-dpctl.8.in b/utilities/ovs-dpctl.8.in
index 12fa27bfa..58b3ea0ea 100644
--- a/utilities/ovs-dpctl.8.in
+++ b/utilities/ovs-dpctl.8.in
@@ -46,7 +46,7 @@ Deletes datapath \fIdp\fR. If \fIdp\fR is associated with any network
devices, they are automatically removed.
.
.TP
-\fBadd\-if \fIdp netdev\fR[\fIoption\fR...]...
+\fBadd\-if \fIdp netdev\fR[\fB,\fIoption\fR]...
Adds each \fInetdev\fR to the set of network devices datapath
\fIdp\fR monitors, where \fIdp\fR is the name of an existing
datapath, and \fInetdev\fR is the name of one of the host's
diff --git a/utilities/ovs-dpctl.c b/utilities/ovs-dpctl.c
index f79909a1f..658f6ba10 100644
--- a/utilities/ovs-dpctl.c
+++ b/utilities/ovs-dpctl.c
@@ -241,7 +241,7 @@ do_add_if(int argc OVS_UNUSED, char *argv[])
}
shash_init(&args);
- while ((option = strtok_r(NULL, "", &save_ptr)) != NULL) {
+ while ((option = strtok_r(NULL, ",", &save_ptr)) != NULL) {
char *save_ptr_2 = NULL;
char *key, *value;