mirror of
https://github.com/GOSTSec/sgminer
synced 2025-01-23 04:54:26 +00:00
Presumably we should return false when the capability is missing in libztex_checkCapability.
This commit is contained in:
parent
78a32f2ebc
commit
b97e6aa5a0
@ -64,8 +64,10 @@ static bool libztex_checkDevice(struct libusb_device *dev)
|
|||||||
static bool libztex_checkCapability(struct libztex_device *ztex, int i, int j)
|
static bool libztex_checkCapability(struct libztex_device *ztex, int i, int j)
|
||||||
{
|
{
|
||||||
if (!((i >= 0) && (i <= 5) && (j >= 0) && (j < 8) &&
|
if (!((i >= 0) && (i <= 5) && (j >= 0) && (j < 8) &&
|
||||||
(((ztex->interfaceCapabilities[i] & 255) & (1 << j)) != 0)))
|
(((ztex->interfaceCapabilities[i] & 255) & (1 << j)) != 0))) {
|
||||||
applog(LOG_ERR, "%s: capability missing: %d %d", ztex->repr, i, i);
|
applog(LOG_ERR, "%s: capability missing: %d %d", ztex->repr, i, i);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user