Browse Source

Remove the unqueued work reference when we discard work from get queued as well.

Con Kolivas 12 years ago
parent
commit
272dfc04fd
1 changed files with 2 additions and 3 deletions
  1. 2 3
      miner.c

+ 2 - 3
miner.c

@@ -9115,11 +9115,10 @@ struct work *get_queued(struct cgpu_info *cgpu)
 			work = NULL;
 			work = NULL;
 			wake_gws();
 			wake_gws();
 			goto out_unlock;
 			goto out_unlock;
-		}
-		__add_queued(cgpu, work);
+		} else
+			__add_queued(cgpu, work);
 		cgpu->unqueued_work = NULL;
 		cgpu->unqueued_work = NULL;
 	}
 	}
-out_unlock:
 	wr_unlock(&cgpu->qlock);
 	wr_unlock(&cgpu->qlock);
 
 
 	return work;
 	return work;