tcmu: return on first Opt parse failure

We only were returing failure if the last opt to be parsed failed.
This has a return failure when we first detect a failure.

Signed-off-by: Mike Christie <mchristi@redhat.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
This commit is contained in:
Mike Christie 2017-03-01 23:14:40 -06:00 committed by Nicholas Bellinger
parent 3abaa2bfdb
commit 2579325ca0

View File

@ -1118,6 +1118,9 @@ static ssize_t tcmu_set_configfs_dev_params(struct se_device *dev,
default:
break;
}
if (ret)
break;
}
kfree(orig);