diff options
Diffstat (limited to 'pkt.h')
-rw-r--r-- | pkt.h | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -59,6 +59,13 @@ static inline void pkt_free(struct pkt *p) free(p); } +static inline void pkt_reset(struct pkt *p) +{ + assert(pkt_invariant(p)); + + p->tail = p->data; +} + static inline size_t pkt_len(struct pkt *p) { assert(pkt_invariant(p)); |