util-linux/misc-utils
Karel Zak dc30fd4383 libblkid: check for medium on CDMROMs probing
The commit 39f5af2598 introduces
O_NONBLOCK to avoid the tray close on open(). The side effect is that
open() is successful when there is no medium.

This is usually no problem for standard tools because the next read()
will fail. Unfortunately, libblkid ignores I/O errors for (and only
for) CDROMs to support some crazy hybrid data+audio disks. The final
result is many I/O errors in system log when O_NONBLOCK is enabled.

This patch add CDROM_DRIVE_STATUS to stop probing when there is no
disk or when the tray is open.

Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=1787973
Signed-off-by: Karel Zak <kzak@redhat.com>
2020-01-07 16:48:34 +01:00
..
.gitignore chkdupexe: remove, deprecated for years 2013-03-14 13:34:11 +01:00
Makemodule.am Merge branch 'hardlink' of https://github.com/rudimeier/util-linux into hardlink 2019-02-06 13:55:20 +01:00
blkid.8 man pages: Change a HYPHEN-MINUS (-) to a minus (\-) for options and numbers 2019-12-17 12:32:43 +01:00
blkid.c libblkid: check for medium on CDMROMs probing 2020-01-07 16:48:34 +01:00
cal.1 cal: (man) make -w, -m and --iso relation more obvious 2020-01-03 12:04:00 +01:00
cal.c po: remove possibility to translate static option arguments 2019-08-24 09:29:52 +01:00
fincore.1 docs: try to find broken man references and fix them 2019-08-26 19:43:40 +01:00
fincore.c cleanup: Remove some spurious spaces 2019-10-01 13:01:43 +02:00
findfs.8 man: Use the correct macro for a font change of one argument 2018-05-23 10:43:27 +02:00
findfs.c misc: consolidate version printing and close_stdout() 2019-04-16 15:14:13 +02:00
findmnt-verify.c findmnt: (verify) ignore passno for XFS 2019-06-12 11:03:23 +02:00
findmnt.8 man pages: Add a comma after "e.g." and "i.e." 2019-12-17 12:32:43 +01:00
findmnt.c findmnt: fix filters use on --list 2019-05-29 17:59:33 +02:00
findmnt.h misc-tools/findmnt: add --pseudo, --real filters 2018-05-10 11:58:30 -05:00
getopt-parse.bash getops: make --a-long option work again 2017-05-16 14:54:41 +02:00
getopt-parse.tcsh getops: improve getopt-parse.bash example 2016-07-27 16:08:43 +01:00
getopt.1 misc-utils/getopt.1: minor corrections to the manual 2018-04-06 13:10:23 +02:00
getopt.c misc: consolidate version printing and close_stdout() 2019-04-16 15:14:13 +02:00
hardlink.1 man pages: Change a HYPHEN-MINUS (-) to a minus (\-) for options and numbers 2019-12-17 12:32:43 +01:00
hardlink.c hardlink: avoid uninitialized variables [clang scan] 2019-05-23 12:12:07 +02:00
kill.1 man pages: Change a HYPHEN-MINUS (-) to a minus (\-) for options and numbers 2019-12-17 12:32:43 +01:00
kill.c kill: add another ifdef 2019-12-10 11:07:30 +01:00
logger.1 man pages: Add a comma after "e.g." and "i.e." 2019-12-17 12:32:43 +01:00
logger.c logger: make code more robust for static analyzer [clang scan] 2019-05-23 12:14:10 +02:00
look.1 man pages: Change a HYPHEN-MINUS (-) to a minus (\-) for options and numbers 2019-12-17 12:32:43 +01:00
look.c misc: consolidate version printing and close_stdout() 2019-04-16 15:14:13 +02:00
lsblk-devtree.c lsblk: fix -E segfault 2019-07-15 12:28:26 +02:00
lsblk-mnt.c lsblk: rename blkdev_cxt to lsblk_device 2018-12-07 12:32:57 +01:00
lsblk-properties.c lsblk: add PARTTYPENAME column 2019-12-04 12:38:57 +01:00
lsblk.8 man pages: Change a HYPHEN-MINUS (-) to a minus (\-) for options and numbers 2019-12-17 12:32:43 +01:00
lsblk.c lsblk: add PARTTYPENAME column 2019-12-04 12:38:57 +01:00
lsblk.h lsblk: add PARTTYPENAME column 2019-12-04 12:38:57 +01:00
lslocks.8 man pages: Change a HYPHEN-MINUS (-) to a minus (\-) for options and numbers 2019-12-17 12:32:43 +01:00
lslocks.c misc: consolidate version printing and close_stdout() 2019-04-16 15:14:13 +02:00
mcookie.1 docs: try to find broken man references and fix them 2019-08-26 19:43:40 +01:00
mcookie.c cleanup: Remove some spurious spaces 2019-10-01 13:01:43 +02:00
namei.1 docs: replace FTP by HTTPS in kernel.org URLs 2016-12-19 11:22:26 +01:00
namei.c misc: consolidate version printing and close_stdout() 2019-04-16 15:14:13 +02:00
rename.1 man pages: Change a HYPHEN-MINUS (-) to a minus (\-) for options and numbers 2019-12-17 12:32:43 +01:00
rename.c misc: consolidate version printing and close_stdout() 2019-04-16 15:14:13 +02:00
test_uuidd.c misc: replace magic number 37 with UUID_STR_LEN 2017-09-05 11:49:21 +02:00
uuidd.8.in man pages: Change a HYPHEN-MINUS (-) to a minus (\-) for options and numbers 2019-12-17 12:32:43 +01:00
uuidd.c misc: consolidate version printing and close_stdout() 2019-04-16 15:14:13 +02:00
uuidd.rc.in build: use --runstatedir instead of --localstatedir 2017-07-31 15:24:46 +02:00
uuidd.service.in uuidd: Add hardening settings to uuidd.service 2018-11-29 10:37:08 +01:00
uuidd.socket.in build: use --runstatedir instead of --localstatedir 2017-07-31 15:24:46 +02:00
uuidgen.1 misc: fix typos using codespell 2018-02-16 11:12:52 +01:00
uuidgen.c misc: consolidate version printing and close_stdout() 2019-04-16 15:14:13 +02:00
uuidparse.1 Fix man page typos 2018-08-16 11:09:15 +02:00
uuidparse.c misc: consolidate version printing and close_stdout() 2019-04-16 15:14:13 +02:00
whereis.1 man pages: Change a HYPHEN-MINUS (-) to a minus (\-) for options and numbers 2019-12-17 12:32:43 +01:00
whereis.c whereis: make subdirs scan more robust 2019-05-23 13:53:00 +02:00
wipefs.8 man pages: Change a HYPHEN-MINUS (-) to a minus (\-) for options and numbers 2019-12-17 12:32:43 +01:00
wipefs.c libblkid: open device in nonblock mode. 2019-11-06 09:55:49 +01:00