1
0
mirror of https://github.com/systemd/systemd.git synced 2024-11-01 09:21:26 +03:00

udev: hwdb validate() return when the database is not opened

This commit is contained in:
Kay Sievers 2012-10-25 22:08:33 +02:00
parent 1c574591db
commit 7ee40fc3e9

View File

@ -357,6 +357,8 @@ static bool builtin_hwdb_validate(struct udev *udev)
{
struct stat st;
if (!trie.f)
return true;
if (fstat(fileno(trie.f), &st) < 0)
return true;
if (trie.file_time_usec != ts_usec(&st.st_mtim))