aio.7: Use perror() directly

Signed-off-by: Alejandro Colomar <colomar.6.4.3@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Alejandro Colomar 2020-09-10 23:13:42 +02:00 committed by Michael Kerrisk
parent e85fd9034f
commit b8c40f8946
1 changed files with 2 additions and 4 deletions

View File

@ -257,8 +257,6 @@ aio_return():
#define errExit(msg) do { perror(msg); exit(EXIT_FAILURE); } while (0)
#define errMsg(msg) do { perror(msg); } while (0)
struct ioRequest { /* Application\-defined structure for tracking
I/O requests */
int reqNum;
@ -390,7 +388,7 @@ main(int argc, char *argv[])
else if (s == AIO_ALLDONE)
printf("I/O all done\en");
else
errMsg("aio_cancel");
perror("aio_cancel");
}
}
@ -418,7 +416,7 @@ main(int argc, char *argv[])
printf("Canceled\en");
break;
default:
errMsg("aio_error");
perror("aio_error");
break;
}