mirror of
https://github.com/skot/ESP-Miner.git
synced 2025-04-10 12:59:25 +02:00
admin: only abandon work if there is work to abandon
This commit is contained in:
parent
96217bc9a7
commit
474f98d070
@ -230,7 +230,7 @@ static void admin_task(void *pvParameters)
|
||||
|
||||
stratum_method method = parse_stratum_method(line);
|
||||
if (method == MINING_NOTIFY) {
|
||||
if (should_abandon_work(line)) {
|
||||
if (should_abandon_work(line) && g_queue.count > 0) {
|
||||
ESP_LOGI(TAG, "Should abandon work, clearing queues");
|
||||
abandon_work = 1;
|
||||
queue_clear(&g_queue);
|
||||
|
Loading…
x
Reference in New Issue
Block a user