head and data always had the same value. head was in the minority, so replace with data where it was used. Signed-off-by: Duncan Roe <duncan_roe@xxxxxxxxxxxxxxx> --- src/extra/pktbuff.c | 5 ++--- src/internal.h | 1 - 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/extra/pktbuff.c b/src/extra/pktbuff.c index f013cfe..c95384f 100644 --- a/src/extra/pktbuff.c +++ b/src/extra/pktbuff.c @@ -66,9 +66,8 @@ struct pkt_buff *pktb_alloc(int family, void *data, size_t len, size_t extra) pktb->len = len; pktb->data_len = len + extra; - pktb->head = pkt_data; pktb->data = pkt_data; - pktb->tail = pktb->head + len; + pktb->tail = pktb->data + len; switch(family) { case AF_INET: @@ -204,7 +203,7 @@ EXPORT_SYMBOL void pktb_trim(struct pkt_buff *pktb, unsigned int len) { pktb->len = len; - pktb->tail = pktb->head + len; + pktb->tail = pktb->data + len; } /** diff --git a/src/internal.h b/src/internal.h index d968325..0cfa425 100644 --- a/src/internal.h +++ b/src/internal.h @@ -23,7 +23,6 @@ struct pkt_buff { uint8_t *network_header; uint8_t *transport_header; - uint8_t *head; uint8_t *data; uint8_t *tail; -- 2.14.5