mirror of
https://gitlab.freedesktop.org/dbus/dbus.git
synced 2026-02-04 14:10:28 +01:00
desktop-file: Justify implementation of is_valid_section_name()
Signed-off-by: Simon McVittie <smcv@collabora.com>
(cherry picked from commit 99580298f3)
This commit is contained in:
parent
2b09942986
commit
2e4a72ed51
1 changed files with 6 additions and 1 deletions
|
|
@ -378,7 +378,12 @@ parse_comment_or_blank (BusDesktopFileParser *parser)
|
|||
static dbus_bool_t
|
||||
is_valid_section_name (const char *name)
|
||||
{
|
||||
/* 5. Group names may contain all ASCII characters except for control characters and '[' and ']'. */
|
||||
/* 5. Group names may contain all ASCII characters except for control characters and '[' and ']'.
|
||||
*
|
||||
* We don't use isprint() here because it's locale-dependent. ASCII
|
||||
* characters <= 0x1f and 0x7f are control characters, and bytes with
|
||||
* values >= 0x80 aren't ASCII. 0x20 is a space, which we must allow,
|
||||
* not least because DBUS_SERVICE_SECTION contains one. */
|
||||
|
||||
while (*name)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue