Ignore responses from bflsc as INPROCESS
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55
diff --git a/driver-bflsc.c b/driver-bflsc.c
index 423832e..e0d556b 100644
--- a/driver-bflsc.c
+++ b/driver-bflsc.c
@@ -1302,7 +1302,7 @@ static int process_results(struct cgpu_info *bflsc, int dev, char *buf, int *non
{
struct bflsc_info *sc_info = (struct bflsc_info *)(bflsc->device_data);
char **items, *firstname, **fields, *lf;
- int que, i, lines, count;
+ int que = 0, i, lines, count;
char xlink[17];
char *tmp, *tmp2;
bool res;
@@ -1311,13 +1311,19 @@ static int process_results(struct cgpu_info *bflsc, int dev, char *buf, int *non
xlinkstr(xlink, sizeof(xlink), dev, sc_info);
+ if (!strncasecmp(buf, BFLSC_INPROCESS, BFLSC_INPROCESS_LEN)) {
+ tmp = str_text(buf);
+ applog(LOG_WARNING, "%s%i:%s in process response (%s) ignored",
+ bflsc->drv->name, bflsc->device_id, xlink, tmp);
+ free(tmp);
+ goto arigatou;
+ }
res = tolines(bflsc, dev, buf, &lines, &items, C_GETRESULTS);
if (!res || lines < 1) {
tmp = str_text(buf);
applog(LOG_ERR, "%s%i:%s empty result (%s) ignored",
bflsc->drv->name, bflsc->device_id, xlink, tmp);
free(tmp);
- que = 0;
goto arigatou;
}
@@ -1326,7 +1332,6 @@ static int process_results(struct cgpu_info *bflsc, int dev, char *buf, int *non
applog(LOG_ERR, "%s%i:%s result too small (%s) ignored",
bflsc->drv->name, bflsc->device_id, xlink, tmp);
free(tmp);
- que = 0;
goto arigatou;
}
diff --git a/driver-bflsc.h b/driver-bflsc.h
index 08d75ac..7107c0e 100644
--- a/driver-bflsc.h
+++ b/driver-bflsc.h
@@ -263,6 +263,8 @@ struct SaveString {
#define BFLSC_ERRSIG_LEN (sizeof(BFLSC_ERRSIG)-1)
#define BFLSC_OKQ "OK:QUEUED"
#define BFLSC_OKQ_LEN (sizeof(BFLSC_OKQ)-1)
+#define BFLSC_INPROCESS "INPROCESS"
+#define BFLSC_INPROCESS_LEN (sizeof(BFLSC_INPROCESS)-1)
// Followed by N=1..5
#define BFLSC_OKQN "OK:QUEUED "
#define BFLSC_OKQN_LEN (sizeof(BFLSC_OKQN)-1)