2008-01-29 Alexander Larsson <alexl@redhat.com>
* gcontenttype.c (looks_like_text):
Don't treat whitespace as control chars.
svn path=/trunk/; revision=6414
2008-01-29 Alexander Larsson <alexl@redhat.com>
+ * gcontenttype.c (looks_like_text):
+ Don't treat whitespace as control chars.
+
+2008-01-29 Alexander Larsson <alexl@redhat.com>
+
* gdesktopappinfo.c:
Lazily create the desktop files for appinfos created
by g_app_info_create_from_commandline() when needed
looks_like_text (const guchar *data, gsize data_size)
{
gsize i;
+ char c;
+
for (i = 0; i < data_size; i++)
{
- if g_ascii_iscntrl (data[i])
+ c = data[i];
+
+ if (g_ascii_iscntrl (c) &&
+ !g_ascii_isspace (c))
return FALSE;
}
return TRUE;