/* Use XSI-compliant portable version of strerror_r() */
#undef _GNU_SOURCE
-#include <stdint.h>
#include <stdio.h>
#include <string.h>
-#include <stdarg.h>
-#include <errno.h>
#include <rte_per_lcore.h>
#include <rte_errno.h>
-#include <rte_string_fns.h>
#ifdef RTE_EXEC_ENV_WINDOWS
#define strerror_r(errnum, buf, buflen) strerror_s(buf, buflen, errnum)
/* since some implementations of strerror_r throw an error
* themselves if errnum is too big, we handle that case here */
if (errnum >= RTE_MAX_ERRNO)
+#ifdef RTE_EXEC_ENV_WINDOWS
+ snprintf(ret, RETVAL_SZ, "Unknown error");
+#else
snprintf(ret, RETVAL_SZ, "Unknown error%s %d", sep, errnum);
+#endif
else
switch (errnum){
case E_RTE_SECONDARY: