}
}
+ /* The datapath name is not a mandatory parameter for this command.
+ * If it is not specified - so argc == 1 - we retrieve it from the
+ * current setup, assuming only one exists. */
name = (argc > 1) ? xstrdup(argv[1]) : get_one_dp(dpctl_p);
if (!name) {
error = EINVAL;
struct simap port_names;
int n, error;
+ /* The datapath name is not a mandatory parameter for this command.
+ * If it is not specified - so argc < 4 - we retrieve it from the
+ * current setup, assuming only one exists. */
dp_name = argc == 4 ? xstrdup(argv[1]) : get_one_dp(dpctl_p);
if (!dp_name) {
return EINVAL;
struct ds ds;
int n, error;
+ /* The datapath name is not a mandatory parameter for this command.
+ * If it is not specified - so argc < 3 - we retrieve it from the
+ * current setup, assuming only one exists. */
dp_name = argc == 3 ? xstrdup(argv[1]) : get_one_dp(dpctl_p);
if (!dp_name) {
return EINVAL;
struct simap port_names;
int n, error;
+ /* The datapath name is not a mandatory parameter for this command.
+ * If it is not specified - so argc < 3 - we retrieve it from the
+ * current setup, assuming only one exists. */
dp_name = argc == 3 ? xstrdup(argv[1]) : get_one_dp(dpctl_p);
if (!dp_name) {
return EINVAL;
char *name;
int error;
+ /* The datapath name is not a mandatory parameter for this command.
+ * If it is not specified - so argc < 2 - we retrieve it from the
+ * current setup, assuming only one exists. */
name = (argc == 2) ? xstrdup(argv[1]) : get_one_dp(dpctl_p);
if (!name) {
return EINVAL;
pzone = &zone;
argc--;
}
+ /* The datapath name is not a mandatory parameter for this command.
+ * If it is not specified - so argc < 2 - we retrieve it from the
+ * current setup, assuming only one exists. */
name = (argc == 2) ? xstrdup(argv[1]) : get_one_dp(dpctl_p);
if (!name) {
return EINVAL;
pzone = &zone;
argc--;
}
+ /* The datapath name is not a mandatory parameter for this command.
+ * If it is not specified - so argc < 2 - we retrieve it from the
+ * current setup, assuming only one exists. */
name = (argc == 2) ? xstrdup(argv[1]) : get_one_dp(dpctl_p);
if (!name) {
return EINVAL;
}
}
}
-
+ /* The datapath name is not a mandatory parameter for this command.
+ * If it is not specified - so argc == 1 - we retrieve it from the
+ * current setup, assuming only one exists. */
name = (argc > 1) ? xstrdup(argv[1]) : get_one_dp(dpctl_p);
if (!name) {
return EINVAL;
}
}
+ /* The datapath name is not a mandatory parameter for this command.
+ * If it is not specified - so argc < 2 - we retrieve it from the
+ * current setup, assuming only one exists. */
name = (argc == 2) ? xstrdup(argv[1]) : get_one_dp(dpctl_p);
if (!name) {
return EINVAL;