block/stream: Don't stream unbacked devices
commitf4a193e717e6b5179a2e57423bfe110b724662d8
authorMax Reitz <mreitz@redhat.com>
Wed, 13 Nov 2013 19:37:58 +0000 (13 20:37 +0100)
committerKevin Wolf <kwolf@redhat.com>
Thu, 28 Nov 2013 10:39:31 +0000 (28 11:39 +0100)
treeeee9919b69c91f27618531e602d0b45aa6ffbf76
parent8582972227196c289bb3b28086b3b2d01071d958
block/stream: Don't stream unbacked devices

If a block device is unbacked, a streaming blockjob should immediately
finish instead of beginning to try to stream, then noticing the backing
file does not contain even the first sector (since it does not exist)
and then finishing normally.

Signed-off-by: Max Reitz <mreitz@redhat.com>
Reviewed-by: Wenchao Xia <xiawenc@linux.vnet.ibm.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block/stream.c