mirror of
https://github.com/GOSTSec/sgminer
synced 2025-02-02 10:04:33 +00:00
Ztex device removal segfault fixed
This commit is contained in:
parent
261677d1ac
commit
a960087c0a
@ -420,7 +420,7 @@ int libztex_scanDevices (struct libztex_dev_list*** devs_p) {
|
|||||||
|
|
||||||
int libztex_sendHashData (struct libztex_device *ztex, unsigned char *sendbuf) {
|
int libztex_sendHashData (struct libztex_device *ztex, unsigned char *sendbuf) {
|
||||||
int cnt;
|
int cnt;
|
||||||
if (ztex->hndl == NULL) {
|
if (ztex == NULL || ztex->hndl == NULL) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
cnt = libusb_control_transfer(ztex->hndl, 0x40, 0x80, 0, 0, sendbuf, 44, 1000);
|
cnt = libusb_control_transfer(ztex->hndl, 0x40, 0x80, 0, 0, sendbuf, 44, 1000);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user