The function strerror() is insecure in a multi-thread environment.
This patch uses rte_strerror() to replace it.

Cc: sta...@dpdk.org

Signed-off-by: Dengdui Huang <huangdeng...@huawei.com>
Acked-by: Chengwen Feng <fengcheng...@huawei.com>
---
 drivers/net/enetfec/enet_uio.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/enetfec/enet_uio.c b/drivers/net/enetfec/enet_uio.c
index 6539cbb354..93520e9760 100644
--- a/drivers/net/enetfec/enet_uio.c
+++ b/drivers/net/enetfec/enet_uio.c
@@ -231,7 +231,7 @@ enetfec_configure(void)
        d = opendir(FEC_UIO_DEVICE_SYS_ATTR_PATH);
        if (d == NULL) {
                ENETFEC_PMD_ERR("\nError opening directory '%s': %s\n",
-                       FEC_UIO_DEVICE_SYS_ATTR_PATH, strerror(errno));
+                       FEC_UIO_DEVICE_SYS_ATTR_PATH, rte_strerror(errno));
                return -1;
        }
 
-- 
2.33.0

Reply via email to