[gtk+] Fix color name (as of rgb.txt) parsing in symbolic colors
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] Fix color name (as of rgb.txt) parsing in symbolic colors
- Date: Fri, 24 Dec 2010 18:49:48 +0000 (UTC)
commit e5e95934bac824d5cbf791491bbc3a3374604935
Author: Carlos Garnacho <carlosg gnome org>
Date: Tue Dec 21 18:44:53 2010 +0100
Fix color name (as of rgb.txt) parsing in symbolic colors
The end of the substring wasn't being detected properly.
gtk/gtkcssprovider.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/gtk/gtkcssprovider.c b/gtk/gtkcssprovider.c
index c318ec9..c8d7624 100644
--- a/gtk/gtkcssprovider.c
+++ b/gtk/gtkcssprovider.c
@@ -2116,8 +2116,9 @@ symbolic_color_parse_str (const gchar *string,
}
else
{
- /* color name? parse until first whitespace */
- while (*end != ' ' && *end != '\0')
+ /* Color name */
+ while (*end != '\0' &&
+ (g_ascii_isalnum (*end) || *end == ' '))
end++;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]