From 392275eed3f0895f9d693d94058af04f916f1636 Mon Sep 17 00:00:00 2001 From: Moritz Lipp Date: Sun, 12 Feb 2012 11:16:10 +0100 Subject: [PATCH] Resolve sc_follow issue --- shortcuts.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/shortcuts.c b/shortcuts.c index 8ec1f4f..da5d386 100644 --- a/shortcuts.c +++ b/shortcuts.c @@ -120,7 +120,7 @@ sc_follow(girara_session_t* session, girara_argument_t* UNUSED(argument), g_return_val_if_fail(session->global.data != NULL, false); zathura_t* zathura = session->global.data; - if (zathura->document == NULL) { + if (zathura->document == NULL || zathura->ui.session == NULL) { return false; } @@ -151,7 +151,7 @@ sc_follow(girara_session_t* session, girara_argument_t* UNUSED(argument), /* ask for input */ if (show_links == true) { - girara_dialog(zathura->ui.session, "Follow link:", FALSE, NULL, (girara_callback_inputbar_activate_t) cb_sc_follow, NULL); + girara_dialog(zathura->ui.session, "Follow link:", FALSE, NULL, (girara_callback_inputbar_activate_t) cb_sc_follow, zathura->ui.session); } return false;