Skip to content
Snippets Groups Projects
Commit 2c46c79f authored by Martine Lenders's avatar Martine Lenders
Browse files

pktbuf: fix snip-was-head case for pktbuf_remove_snip

parent e9fb853a
No related branches found
No related tags found
No related merge requests found
...@@ -172,12 +172,17 @@ ng_pktsnip_t *ng_pktbuf_start_write(ng_pktsnip_t *pkt); ...@@ -172,12 +172,17 @@ ng_pktsnip_t *ng_pktbuf_start_write(ng_pktsnip_t *pkt);
* *
* @param[in] pkt A packet. * @param[in] pkt A packet.
* @param[in] snip A snip in the packet. * @param[in] snip A snip in the packet.
*
* @return The new reference to @p pkt.
*/ */
static inline void ng_pktbuf_remove_snip(ng_pktsnip_t *pkt, ng_pktsnip_t *snip) static inline ng_pktsnip_t *ng_pktbuf_remove_snip(ng_pktsnip_t *pkt,
ng_pktsnip_t *snip)
{ {
LL_DELETE(pkt, snip); LL_DELETE(pkt, snip);
snip->next = NULL; snip->next = NULL;
ng_pktbuf_release(snip); ng_pktbuf_release(snip);
return pkt;
} }
#ifdef DEVELHELP #ifdef DEVELHELP
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment