block/sheepdog: remove spurious NULL check
'tag' is already checked in the lines immediately preceding this check, and set to non-NULL if NULL. No need to check again, it hasn't changed. Signed-off-by: Jeff Cody <jcody@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Darren Kenny <darren.kenny@oracle.com> Signed-off-by: Jeff Cody <jcody@redhat.com>
This commit is contained in:
parent
aa9ef2e65b
commit
ac90dad94b
@ -1632,7 +1632,7 @@ static int sd_open(BlockDriverState *bs, QDict *options, int flags,
|
||||
if (!tag) {
|
||||
tag = "";
|
||||
}
|
||||
if (tag && strlen(tag) >= SD_MAX_VDI_TAG_LEN) {
|
||||
if (strlen(tag) >= SD_MAX_VDI_TAG_LEN) {
|
||||
error_setg(errp, "value of parameter 'tag' is too long");
|
||||
ret = -EINVAL;
|
||||
goto err_no_fd;
|
||||
|
Loading…
Reference in New Issue
Block a user