1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-12-24 21:34:08 +03:00

localed: consider an unset model as a wildcard

This commit is contained in:
Michal Sekletar 2014-05-30 18:20:16 +02:00 committed by Lennart Poettering
parent 5e91345094
commit 387066c2e5

View File

@ -712,8 +712,8 @@ static int find_legacy_keymap(Context *c, char **new_keymap) {
}
}
if (matching > 0 &&
streq_ptr(c->x11_model, a[2])) {
if (matching > 0) {
if (isempty(c->x11_model) || streq_ptr(c->x11_model, a[2])) {
matching++;
if (streq_ptr(c->x11_variant, a[3])) {
@ -723,6 +723,7 @@ static int find_legacy_keymap(Context *c, char **new_keymap) {
matching++;
}
}
}
/* The best matching entry so far, then let's save that */
if (matching > best_matching) {