Skip to content
Permalink
Browse files
Remove fprintf, set errno instead.
Remove the fprintf statements in the windows platform implementation of
the POSIX opendir function, and set errno with the error value instead.

Closes: AXIS2c-1674
  • Loading branch information
bblough committed Sep 2, 2020
1 parent 8386b12 commit 5d48db79bf0de36761dec7c2e9dcad45d22148bd
Showing 1 changed file with 2 additions and 3 deletions.
@@ -51,15 +51,14 @@ axis2_opendir(
if (dwErr == ERROR_FILE_NOT_FOUND || dwErr == ERROR_PATH_NOT_FOUND
|| dwErr == ERROR_NO_MORE_FILES || dwErr == ERROR_NOT_READY)
{
fprintf(stderr, "FindFirstFile with unexpected result. Error code: %u\r\n", dwErr);

errno = dwErr;
dirp->finished = 1;
}
else
{
free(dirp);
free(filespec);
fprintf(stderr, "FindFirstFile failed. Error code: %u\r\n", dwErr);
errno = dwErr;
return NULL;
}
}

0 comments on commit 5d48db7

Please sign in to comment.