Update librte-pmd-bond1.symbols with new symbol.
[deb_dpdk.git] / lib / librte_pdump / rte_pdump.c
index 5968683..1a5147a 100644 (file)
@@ -154,6 +154,8 @@ pdump_pktmbuf_copy(struct rte_mbuf *m, struct rte_mempool *mp)
        do {
                nseg++;
                if (pdump_pktmbuf_copy_data(seg, m) < 0) {
+                       if (seg != m_dup)
+                               rte_pktmbuf_free_seg(seg);
                        rte_pktmbuf_free(m_dup);
                        return NULL;
                }
@@ -580,7 +582,7 @@ rte_pdump_init(const char *path)
        if (ret != 0) {
                RTE_LOG(ERR, PDUMP,
                        "Failed to create the pdump thread:%s, %s:%d\n",
-                       strerror(errno), __func__, __LINE__);
+                       strerror(ret), __func__, __LINE__);
                return -1;
        }
        /* Set thread_name for aid in debugging. */
@@ -603,7 +605,7 @@ rte_pdump_uninit(void)
        if (ret != 0) {
                RTE_LOG(ERR, PDUMP,
                        "Failed to cancel the pdump thread:%s, %s:%d\n",
-                       strerror(errno), __func__, __LINE__);
+                       strerror(ret), __func__, __LINE__);
                return -1;
        }