From c791ee64b8c0bf0c58f026a90df549bf00ecef2c Mon Sep 17 00:00:00 2001 From: raveit65 Date: Fri, 24 Jun 2016 18:32:07 +0200 Subject: Refresh thumbnail only when window has a document This prevents a critical warning when opening a document that was rotated in a previous Evince session. taken from: https://git.gnome.org/browse/evince/commit/?id=1b5cf70 --- shell/ev-window.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'shell') diff --git a/shell/ev-window.c b/shell/ev-window.c index e30d36d2..67fe7e77 100644 --- a/shell/ev-window.c +++ b/shell/ev-window.c @@ -1452,7 +1452,7 @@ ev_window_refresh_window_thumbnail (EvWindow *ev_window) gint rotation; EvDocument *document = ev_window->priv->document; - if (!EV_IS_DOCUMENT_THUMBNAILS (document) || + if (!document || ev_document_get_n_pages (document) <= 0 || ev_document_get_n_pages (document) <= 0 || !ev_document_check_dimensions (document)) { return; -- cgit v1.2.1