Drop rconn's responsibility for limiting the tx queue.

Now it helps clients track the number of in-flight messages, but lets the
clients do the limiting themselves.  This will come in handy for packet-in
rate limiting (in an upcoming commit), in which we want to track in-flight
packet-in messages separately from other in-flight messages.
This commit is contained in:
Ben Pfaff committed 2008-08-12 15:21:30 -07:00
1 parent b3b28afb7b
commit 903d0940fb
11 files changed
+124 -92

No files matched your search

+11
View File
@@ -101,6 +101,17 @@ queue_push_tail(struct queue *q, struct buffer *b)
check_queue(q);
}
/* Removes the first buffer from 'q', which must not be empty, and returns
* it. The caller must free the buffer (with buffer_delete()) when it is no
* longer needed. */
struct buffer *
queue_pop_head(struct queue *q)
{
struct buffer *head = q->head;
queue_advance_head(q, head->next);
return head;
}
/* Checks the internal integrity of 'q'. For use in debugging. */
static void
check_queue(struct queue *q)