mirror of
https://github.com/Motorhead1991/qemu.git
synced 2026-02-23 20:55:05 -07:00
nbd: Fix overflow return value
The value of reply.error should be the type unsigned int. Signed-off-by: Yik Fang <eric.fangyi@huawei.com> Message-Id: <1423722111-12902-1-git-send-email-eric.fangyi@huawei.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
cd232acfa0
commit
8b2f0abfd6
1 changed files with 1 additions and 1 deletions
2
nbd.c
2
nbd.c
|
|
@ -1295,7 +1295,7 @@ static void nbd_trip(void *opaque)
|
|||
default:
|
||||
LOG("invalid request type (%u) received", request.type);
|
||||
invalid_request:
|
||||
reply.error = -EINVAL;
|
||||
reply.error = EINVAL;
|
||||
error_reply:
|
||||
if (nbd_co_send_reply(req, &reply, 0) < 0) {
|
||||
goto out;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue