executor: fix a cast in common_usb_netbsd.h

This commit is contained in:
m00nbsd 2020-05-23 08:44:55 +02:00 committed by Andrey Konovalov
parent 9682898d6f
commit 96c92ad3ab
2 changed files with 4 additions and 4 deletions

View File

@ -293,13 +293,13 @@ static volatile long syz_usb_connect_impl(uint64 speed, uint64 dev_len,
if (req.u.ctrl.bmRequestType & UE_DIR_IN) {
bool response_found = false;
NONFAILING(response_found = lookup_connect_response_in(fd, descs, (const usb_ctrlrequest*)&req.u.ctrl, &response_data, &response_length));
NONFAILING(response_found = lookup_connect_response_in(fd, descs, (const struct usb_ctrlrequest*)&req.u.ctrl, &response_data, &response_length));
if (!response_found) {
debug("syz_usb_connect: unknown control IN request\n");
goto err;
}
} else {
if (!lookup_connect_response_out(fd, descs, (const usb_ctrlrequest*)&req.u.ctrl, &done)) {
if (!lookup_connect_response_out(fd, descs, (const struct usb_ctrlrequest*)&req.u.ctrl, &done)) {
debug("syz_usb_connect: unknown control OUT request\n");
goto err;
}

View File

@ -1475,13 +1475,13 @@ static volatile long syz_usb_connect_impl(uint64 speed, uint64 dev_len,
if (req.u.ctrl.bmRequestType & UE_DIR_IN) {
bool response_found = false;
NONFAILING(response_found = lookup_connect_response_in(fd, descs, (const usb_ctrlrequest*)&req.u.ctrl, &response_data, &response_length));
NONFAILING(response_found = lookup_connect_response_in(fd, descs, (const struct usb_ctrlrequest*)&req.u.ctrl, &response_data, &response_length));
if (!response_found) {
debug("syz_usb_connect: unknown control IN request\n");
goto err;
}
} else {
if (!lookup_connect_response_out(fd, descs, (const usb_ctrlrequest*)&req.u.ctrl, &done)) {
if (!lookup_connect_response_out(fd, descs, (const struct usb_ctrlrequest*)&req.u.ctrl, &done)) {
debug("syz_usb_connect: unknown control OUT request\n");
goto err;
}