| 51 | }; |
| 52 | |
| 53 | static void nonstale_queue_put(struct nonstale_queue *queue, |
| 54 | struct commit *c) |
| 55 | { |
| 56 | struct commit *old = queue->max_nonstale; |
| 57 | |
| 58 | prio_queue_put(&queue->pq, c); |
| 59 | if (c->object.flags & STALE) |
| 60 | return; |
| 61 | if (!old || queue->pq.compare(old, c, queue->pq.cb_data) <= 0) |
| 62 | queue->max_nonstale = c; |
| 63 | } |
| 64 | |
| 65 | static struct commit *nonstale_queue_get(struct nonstale_queue *queue) |
| 66 | { |
no test coverage detected