Gentoo Archives: gentoo-commits

From: "Anthony G. Basile" <blueness@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/eudev:master commit in: src/udev/
Date: Tue, 09 Feb 2021 19:08:09
Message-Id: 1612897654.9d4010a3629ebc1d915b7f2d3e2d7be83d79b4f4.blueness@gentoo
1 commit: 9d4010a3629ebc1d915b7f2d3e2d7be83d79b4f4
2 Author: Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
3 AuthorDate: Tue Feb 9 12:22:37 2021 +0000
4 Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
5 CommitDate: Tue Feb 9 19:07:34 2021 +0000
6 URL: https://gitweb.gentoo.org/proj/eudev.git/commit/?id=9d4010a3
7
8 udevadm: hwdb: allow empty properties
9
10 Backport of https://github.com/systemd/systemd/commit/afe87974dd57741f74dd87165b251886f24c859f.
11
12 Will address shown error
13
14 > Error, empty key or value ' XKB_FIXED_VARIANT' in '/usr/lib/udev/hwdb.d/60-keyboard.hwdb'
15
16 caued by recent changes in sys-apps/hwids-20201207 [Link 1].
17
18 Link 1: https://github.com/gentoo/hwids/commit/f30071bbebc0685c645783024cae0f9f213a1458#diff-7b9ba9c30888b1b5b1fa008f185e4efaff34eaff2c13f35c38b2ae0416cd891eR1840
19 Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org>
20 Signed-off-by: Anthony G. Basile <blueness <AT> gentoo.org>
21
22 src/udev/udevadm-hwdb.c | 5 ++---
23 1 file changed, 2 insertions(+), 3 deletions(-)
24
25 diff --git a/src/udev/udevadm-hwdb.c b/src/udev/udevadm-hwdb.c
26 index 6bc108783..53b1b15c7 100644
27 --- a/src/udev/udevadm-hwdb.c
28 +++ b/src/udev/udevadm-hwdb.c
29 @@ -441,9 +441,8 @@ static int insert_data(struct trie *trie, struct udev_list *match_list,
30 while (isblank(line[0]) && isblank(line[1]))
31 line++;
32
33 - if (isempty(line + 1) || isempty(value)) {
34 - log_error("Warning, empty %s in \"%s=%s\", ignoring",
35 - isempty(line + 1) ? "key" : "value",
36 + if (isempty(line + 1)) {
37 + log_error("Warning, empty key in \"%s=%s\", ignoring",
38 line, value);
39 return -EINVAL;
40 }