diff options
author | Andreas Rammhold <andreas@rammhold.de> | 2017-09-29 00:37:23 +0200 |
---|---|---|
committer | Andreas Rammhold <andreas@rammhold.de> | 2017-10-02 13:09:54 +0200 |
commit | 3742095b27f8df4b195d530b52d15bc5fea70bf1 (patch) | |
tree | 3fc7c3503845b733f1d58366436c0bb672d3613a /src/udev/scsi_id | |
parent | man: move non-target units together (#6934) (diff) | |
download | systemd-3742095b27f8df4b195d530b52d15bc5fea70bf1.tar.xz systemd-3742095b27f8df4b195d530b52d15bc5fea70bf1.zip |
tree-wide: use IN_SET where possible
In addition to the changes from #6933 this handles cases that could be
matched with the included cocci file.
Diffstat (limited to 'src/udev/scsi_id')
-rw-r--r-- | src/udev/scsi_id/scsi_serial.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/udev/scsi_id/scsi_serial.c b/src/udev/scsi_id/scsi_serial.c index e079e28698..f007cc6001 100644 --- a/src/udev/scsi_id/scsi_serial.c +++ b/src/udev/scsi_id/scsi_serial.c @@ -358,7 +358,7 @@ resend: retval = ioctl(fd, SG_IO, io_buf); if (retval < 0) { - if ((errno == EINVAL || errno == ENOSYS) && dev_scsi->use_sg == 4) { + if (IN_SET(errno, EINVAL, ENOSYS) && dev_scsi->use_sg == 4) { dev_scsi->use_sg = 3; goto resend; } |