git: f10dd8af4b4f - main - Reap dead code in lio_kqueue_test and aio_kqueue_test
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 24 Jul 2022 15:34:22 UTC
The branch main has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=f10dd8af4b4fb17173321fac13b3221bf096555a commit f10dd8af4b4fb17173321fac13b3221bf096555a Author: Alan Somers <asomers@FreeBSD.org> AuthorDate: 2022-05-30 18:34:49 +0000 Commit: Alan Somers <asomers@FreeBSD.org> CommitDate: 2022-07-24 15:31:40 +0000 Reap dead code in lio_kqueue_test and aio_kqueue_test MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D35358 --- tests/sys/aio/aio_kqueue_test.c | 5 ++--- tests/sys/aio/lio_kqueue_test.c | 7 ++----- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/tests/sys/aio/aio_kqueue_test.c b/tests/sys/aio/aio_kqueue_test.c index f3e63376eb1b..ac246310f8bc 100644 --- a/tests/sys/aio/aio_kqueue_test.c +++ b/tests/sys/aio/aio_kqueue_test.c @@ -59,7 +59,7 @@ main (int argc, char *argv[]) { struct aiocb **iocb, *kq_iocb; char *file, pathname[sizeof(PATH_TEMPLATE)+1]; - struct kevent ke, kq_returned; + struct kevent kq_returned; struct timespec ts; char buffer[32768]; int max_queue_per_proc; @@ -156,8 +156,7 @@ main (int argc, char *argv[]) for (;;) { - bzero(&ke, sizeof(ke)); - bzero(&kq_returned, sizeof(ke)); + bzero(&kq_returned, sizeof(kq_returned)); ts.tv_sec = 0; ts.tv_nsec = 1; result = kevent(kq, NULL, 0, diff --git a/tests/sys/aio/lio_kqueue_test.c b/tests/sys/aio/lio_kqueue_test.c index 3226573721c6..b85e3630b9b8 100644 --- a/tests/sys/aio/lio_kqueue_test.c +++ b/tests/sys/aio/lio_kqueue_test.c @@ -63,7 +63,7 @@ main(int argc, char *argv[]) size_t max_queue_per_proc_size; char buffer[32768]; int kq; - struct kevent ke, kq_returned; + struct kevent kq_returned; struct timespec ts; struct sigevent sig; time_t time1, time2; @@ -153,15 +153,12 @@ main(int argc, char *argv[]) } for (;;) { - bzero(&ke, sizeof(ke)); - bzero(&kq_returned, sizeof(ke)); + bzero(&kq_returned, sizeof(kq_returned)); ts.tv_sec = 0; ts.tv_nsec = 1; #ifdef DEBUG printf("FOO lio %d -> %p\n", j, lio[j]); #endif - EV_SET(&ke, (uintptr_t)lio[j], - EVFILT_LIO, EV_ONESHOT, 0, 0, iocb[j]); result = kevent(kq, NULL, 0, &kq_returned, 1, &ts); error = errno;