|
|
@@ -163,8 +163,11 @@ bool hashbuster_foundlowl(struct lowlevel_device_info * const info, __maybe_unus
|
|
|
__func__, path);
|
|
|
|
|
|
if ((!hashbuster_io(h, buf, buf)) || buf[1] != 0x07)
|
|
|
+ {
|
|
|
+ hid_close(h);
|
|
|
applogr(false, LOG_DEBUG, "%s: Identify sequence didn't match on %s",
|
|
|
__func__, path);
|
|
|
+ }
|
|
|
|
|
|
struct spi_port spi = {
|
|
|
.txrx = hashbuster_spi_txrx,
|
|
|
@@ -225,7 +228,10 @@ bool hashbuster_init(struct thr_info * const thr)
|
|
|
lowlevel_devinfo_free(cgpu->device_data);
|
|
|
|
|
|
if (!h)
|
|
|
+ {
|
|
|
+ hid_close(h);
|
|
|
applogr(false, LOG_ERR, "%s: Failed to open hid device", cgpu->dev_repr);
|
|
|
+ }
|
|
|
|
|
|
port = malloc(sizeof(*port));
|
|
|
if (!port)
|