]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
MFC 327753: Simplify some logic by merging an if test with a subsequent switch.
authorjhb <jhb@FreeBSD.org>
Tue, 30 Jan 2018 00:38:24 +0000 (00:38 +0000)
committerjhb <jhb@FreeBSD.org>
Tue, 30 Jan 2018 00:38:24 +0000 (00:38 +0000)
commit54dbacd60573e0ec3975f6f417a61fb1b995a259
tree14e683c30c8eb309894489def85411ec2dc820c9
parent838c1f246dc7c9508d01225346a56b8bed5a38de
MFC 327753: Simplify some logic by merging an if test with a subsequent switch.

Specifically, in aio_queue_file() the code was doing this:

   if (opcode == LIO_SYNC) {
       ...
   }

   switch (opcode) {
   ...
   case LIO_SYNC:
       ...
   }

This moves the body of the if statement into the LIO_SYNC case of the
switch statement.

Sponsored by: Chelsio Communications
sys/kern/vfs_aio.c