summaryrefslogtreecommitdiff
path: root/pkt.h
diff options
context:
space:
mode:
authorTobias Klauser <tklauser@distanz.ch>2015-02-06 18:53:09 +0100
committerTobias Klauser <tklauser@distanz.ch>2015-02-06 18:53:09 +0100
commit3d228074abb4b41e30dd7e8266f87f967b304ba8 (patch)
tree00c33859bcae42704292e20b7048d06f50aa52c8 /pkt.h
parent70d3f132f12423a43ee5454f747f58fdde4dfb8e (diff)
pkt: Fix tail pointer initialization error
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Diffstat (limited to 'pkt.h')
-rw-r--r--pkt.h5
1 files changed, 1 insertions, 4 deletions
diff --git a/pkt.h b/pkt.h
index e5f8c82..04302f3 100644
--- a/pkt.h
+++ b/pkt.h
@@ -47,10 +47,7 @@ static inline struct pkt *pkt_alloc(size_t size)
struct pkt *p = xmalloc(sizeof(*q) + size);
uint8_t *data = (uint8_t *)p + sizeof(*p);
- p->head = data;
- p->data = data;
- p->tail = data + size;
- p->size = size;
+ p->head = p->data = p->tail = data;
return p;
}