diff options
author | Lennart Poettering <lennart@poettering.net> | 2009-08-07 00:21:39 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2009-10-17 00:28:29 +0200 |
commit | a0e8a279802aa9f26a3ccf3f8ee27110a1509d19 (patch) | |
tree | 56d1a27c083418e46f9da11bdf5a57ecc17d5b86 /dbus/dbus-desktop-file.c | |
parent | c2021a2ce7c1ea6c3bcbdc684fb547dfa943da09 (diff) |
desktop-file: relax validity checks a bit
Mnimally change the validity checks for deskto files so that the
ConsoleKit database can pass as valid.
Diffstat (limited to 'dbus/dbus-desktop-file.c')
-rw-r--r-- | dbus/dbus-desktop-file.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/dbus/dbus-desktop-file.c b/dbus/dbus-desktop-file.c index 45932398..30ca8438 100644 --- a/dbus/dbus-desktop-file.c +++ b/dbus/dbus-desktop-file.c @@ -71,7 +71,7 @@ static unsigned char valid[256] = { 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x3 , 0x2 , 0x0 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , - 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x0 , 0x0 , 0x0 , 0x0 , 0x2 , + 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x0 , 0x0 , 0x0 , 0x0 , 0x3 , 0x0 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x3 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , 0x0 , @@ -379,8 +379,10 @@ is_valid_section_name (const char *name) while (*name) { - if (!((*name >= 'A' && *name <= 'Z') || (*name >= 'a' || *name <= 'z') || - *name == '\n' || *name == '\t')) + if (!((*name >= 'A' && *name <= 'Z') || + (*name >= 'a' || *name <= 'z') || + (*name >= '0' || *name <= '9') || + *name == '\n' || *name == '\t' || *name == ' ' || *name == '/')) return FALSE; name++; |