From: Christian Persch Date: Sun, 15 Feb 2009 13:53:23 +0000 (+0000) Subject: Use g_error_matches. X-Git-Tag: EVINCE_2_25_91~22 X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=commitdiff_plain;h=0cf51a0dc046d0dc6ccc4cbb3ba5a9e06837a1e5;p=evince.git Use g_error_matches. * shell/ev-window.c: (ev_window_load_job_cb): Use g_error_matches. svn path=/trunk/; revision=3458 --- diff --git a/ChangeLog b/ChangeLog index cad652af..672964cf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2009-02-14 Christian Persch + + * shell/ev-window.c: (ev_window_load_job_cb): Use g_error_matches. + 2009-02-14 Christian Persch * backend/pdf/ev-poppler.cc: Plug a mem leak. diff --git a/shell/ev-window.c b/shell/ev-window.c index 618be31d..f950c9b6 100644 --- a/shell/ev-window.c +++ b/shell/ev-window.c @@ -1439,8 +1439,7 @@ ev_window_load_job_cb (EvJob *job, return; } - if (job->error->domain == EV_DOCUMENT_ERROR && - job->error->code == EV_DOCUMENT_ERROR_ENCRYPTED) { + if (g_error_matches (job->error, EV_DOCUMENT_ERROR, EV_DOCUMENT_ERROR_ENCRYPTED)) { gchar *password; setup_view_from_metadata (ev_window);