git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
mbuf: fix reset on mbuf free
[dpdk.git]
/
lib
/
librte_mbuf
/
rte_mbuf.h
diff --git
a/lib/librte_mbuf/rte_mbuf.h
b/lib/librte_mbuf/rte_mbuf.h
index
c4c9ebf
..
8c1097e
100644
(file)
--- a/
lib/librte_mbuf/rte_mbuf.h
+++ b/
lib/librte_mbuf/rte_mbuf.h
@@
-1340,10
+1340,10
@@
rte_pktmbuf_prefree_seg(struct rte_mbuf *m)
return NULL;
}
return NULL;
}
- if (m->next != NULL)
{
+ if (m->next != NULL)
m->next = NULL;
m->next = NULL;
+ if (m->nb_segs != 1)
m->nb_segs = 1;
m->nb_segs = 1;
- }
return m;
return m;
@@
-1357,10
+1357,10
@@
rte_pktmbuf_prefree_seg(struct rte_mbuf *m)
return NULL;
}
return NULL;
}
- if (m->next != NULL)
{
+ if (m->next != NULL)
m->next = NULL;
m->next = NULL;
+ if (m->nb_segs != 1)
m->nb_segs = 1;
m->nb_segs = 1;
- }
rte_mbuf_refcnt_set(m, 1);
return m;
rte_mbuf_refcnt_set(m, 1);
return m;