mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 00:03:54 -06:00
usb: don't use 'Yoda conditions'
imitate nearby code about using '!value' or 'value == NULL' Signed-off-by: Gonglei <arei.gonglei@huawei.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
This commit is contained in:
parent
2bb0020cf9
commit
d0657b2aab
3 changed files with 4 additions and 4 deletions
|
@ -832,7 +832,7 @@ static void usb_mtp_command(MTPState *s, MTPControl *c)
|
|||
return;
|
||||
}
|
||||
data_in = usb_mtp_get_object(s, c, o);
|
||||
if (NULL == data_in) {
|
||||
if (data_in == NULL) {
|
||||
usb_mtp_queue_result(s, RES_GENERAL_ERROR,
|
||||
c->trans, 0, 0, 0);
|
||||
return;
|
||||
|
@ -851,7 +851,7 @@ static void usb_mtp_command(MTPState *s, MTPControl *c)
|
|||
return;
|
||||
}
|
||||
data_in = usb_mtp_get_partial_object(s, c, o);
|
||||
if (NULL == data_in) {
|
||||
if (data_in == NULL) {
|
||||
usb_mtp_queue_result(s, RES_GENERAL_ERROR,
|
||||
c->trans, 0, 0, 0);
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue