]> git.ipfire.org Git - thirdparty/systemd.git/commit
Handle d_type == DT_UNKNOWN correctly
authorMichael Olbrich <m.olbrich@pengutronix.de>
Sun, 29 Sep 2019 11:43:00 +0000 (13:43 +0200)
committerChris Down <chris@chrisdown.name>
Mon, 30 Sep 2019 12:29:59 +0000 (13:29 +0100)
commit28e68bb23547cbc11cd3f62a1a38dbe2b387b370
tree29fa75170fab7bf9e81d0e1e475348a076c0c794
parent501deda1ce89bb558936741c1aeb244e264e8af1
Handle d_type == DT_UNKNOWN correctly

As documented in the man-page, readdir() may return a directory entry with
d_type == DT_UNKNOWN. This must be handled for regular filesystems.

dirent_ensure_type() is available to set d_type if necessary. Use it in
some more places.

Without this systemd will fail to boot correctly with nfsroot and some
other filesystems.

Closes #13609
src/core/smack-setup.c
src/login/logind-dbus.c
src/login/logind.c
src/shared/bootspec.c
src/shared/unit-file.c