Commit e5da6116 authored by Philipp Erhardt's avatar Philipp Erhardt
Browse files

Fix segfault when failing to open a file

parent 15e436e9
......@@ -93,7 +93,9 @@ Canvas::Canvas(Viewer *v, QWidget *parent) :
}
// apply start option
cur_layout->scroll_page(config->get_tmp_value("start_page").toInt(), false);
if (viewer->get_res()->is_valid()) {
cur_layout->scroll_page(config->get_tmp_value("start_page").toInt(), false);
}
setup_keys(this);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment