From: Ondrej Holy Date: Mon, 5 Dec 2016 09:15:12 +0000 (+0100) Subject: info: Do not crash if Renderer is not set by SessionManager X-Git-Tag: archive/raspbian/1%3.26.1-2+rpi1~1^2^2~2 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=9e0161f707401bbd8df4f5a975d5214a75174059;p=gnome-control-center.git 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 Gbp-Pq: Name info-Do-not-crash-if-Renderer-is-not-set-by-SessionM.patch --- diff --git a/panels/info/info-cleanup.c b/panels/info/info-cleanup.c index 20243ec..bb47493 100644 --- a/panels/info/info-cleanup.c +++ b/panels/info/info-cleanup.c @@ -99,6 +99,9 @@ remove_duplicate_whitespace (const char *old) GRegex *re; GError *error; + if (old == NULL) + return NULL; + error = NULL; re = g_regex_new ("[ \t\n\r]+", G_REGEX_MULTILINE, 0, &error); if (re == NULL)