Commit 0f712d519146bd2e2bc4c6b28956f43bbae255e8

Con Kolivas 2013-08-30T20:29:00

Remove inprocess line instead of deleting all following responses in bflsc.

diff --git a/driver-bflsc.c b/driver-bflsc.c
index e0d556b..ea59ddd 100644
--- a/driver-bflsc.c
+++ b/driver-bflsc.c
@@ -108,10 +108,15 @@ static bool tolines(struct cgpu_info *bflsc, int dev, char *buf, int *lines, cha
 
 	ok = true;
 	while (tok) {
-		p_items = realloc(p_items, ++p_lines * sizeof(*p_items));
-		if (unlikely(!p_items))
-			quit(1, "Failed to realloc p_items in tolines");
-		p_items[p_lines-1] = strdup(tok);
+		if (strncasecmp(tok, BFLSC_INPROCESS, BFLSC_INPROCESS_LEN)) {
+			p_items = realloc(p_items, ++p_lines * sizeof(*p_items));
+			if (unlikely(!p_items))
+				quit(1, "Failed to realloc p_items in tolines");
+			p_items[p_lines-1] = strdup(tok);
+		} else {
+			applog(LOG_WARNING, "%s%i: in process response (%s) ignored",
+			       bflsc->drv->name, bflsc->device_id, tok);
+		}
 		tok = strtok(NULL, "\n");
 	}
 
@@ -1311,13 +1316,6 @@ 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);