]> git.proxmox.com Git - mirror_qemu.git/commit - tests/qemu-iotests/051
block: Don't silently truncate node names
authorKevin Wolf <kwolf@redhat.com>
Wed, 4 Jul 2018 11:28:29 +0000 (13:28 +0200)
committerKevin Wolf <kwolf@redhat.com>
Thu, 5 Jul 2018 08:29:19 +0000 (10:29 +0200)
commit824808dd77821ceba05357cb1ee4069a6a95bebd
tree9c5718d645066bd179c898133c6eac1e68122314
parentbfcc224e3cf04ee3fef0eb69984607b5764d9892
block: Don't silently truncate node names

If the user passes a too long node name string, we silently truncate it
to fit into BlockDriverState.node_name, i.e. to 31 characters. Apart
from surprising the user when the node has a different name than
requested, this also bypasses the check for duplicate names, so that the
same name can be assigned to multiple nodes.

Fix this by just making too long node names an error.

Reported-by: Peter Krempa <pkrempa@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block.c
tests/qemu-iotests/051
tests/qemu-iotests/051.out
tests/qemu-iotests/051.pc.out