info: Do not crash if Renderer is not set by SessionManager
This regression has been introduced by commit 52da4da
. The
info panel crashes if prettify_info() returns NULL. This happens
if Renderer property from SessionManager is empty.
https://bugzilla.gnome.org/show_bug.cgi?id=774240
This commit is contained in:
parent
66c7f45307
commit
e8aa9fc0b0
1 changed files with 3 additions and 0 deletions
|
@ -99,6 +99,9 @@ remove_duplicate_whitespace (const char *old)
|
||||||
GRegex *re;
|
GRegex *re;
|
||||||
GError *error;
|
GError *error;
|
||||||
|
|
||||||
|
if (old == NULL)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
error = NULL;
|
error = NULL;
|
||||||
re = g_regex_new ("[ \t\n\r]+", G_REGEX_MULTILINE, 0, &error);
|
re = g_regex_new ("[ \t\n\r]+", G_REGEX_MULTILINE, 0, &error);
|
||||||
if (re == NULL)
|
if (re == NULL)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue