]> git.proxmox.com Git - mirror_qemu.git/commit
usb-mtp: fix error conditions for write operation
authorBandan <bsd@redhat.com>
Fri, 7 Sep 2018 22:08:49 +0000 (18:08 -0400)
committerGerd Hoffmann <kraxel@redhat.com>
Mon, 1 Oct 2018 08:49:53 +0000 (10:49 +0200)
commit44dd4196806ef015e7df3c671ca986b0b5ca0f73
tree108837fb263ad8a854c4cff0654b5fe03cc4ceeb
parent07f426c35eddd79388a23d11cb278600d7e3831d
usb-mtp: fix error conditions for write operation

Return STORE_FULL if we can't write all the bytes but
return incomplete transfer if data received is less then
what was specified in the metadata. Also, use d->offset
as the file size which is valid for all file sizes.

Signed-off-by: Bandan <bsd@redhat.com>
Message-id: 20180907220851.9658-2-bsd@redhat.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
hw/usb/dev-mtp.c