Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ringtest: fix an assert statement

There is an || vs && typo so the assert can never be triggered.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>

authored by

Dan Carpenter and committed by
Michael S. Tsirkin
4f6d9bfc a351e9b9

+1 -1
+1 -1
tools/virtio/ringtest/main.c
··· 86 86 cpu = strtol(arg, &endptr, 0); 87 87 assert(!*endptr); 88 88 89 - assert(cpu >= 0 || cpu < CPU_SETSIZE); 89 + assert(cpu >= 0 && cpu < CPU_SETSIZE); 90 90 91 91 self = pthread_self(); 92 92 CPU_ZERO(&cpuset);