Fix index check.

This commit is contained in:
Sebastian Ramacher 2012-04-02 12:42:55 +02:00
parent 25320f5265
commit b30d021ca0

View file

@ -477,7 +477,7 @@ zathura_page_widget_link_get(ZathuraPage* widget, unsigned int index)
g_return_val_if_fail(priv != NULL, NULL);
if (priv->links != NULL && index >= priv->link_offset &&
girara_list_size(priv->links) >= index - priv->link_offset) {
girara_list_size(priv->links) > index - priv->link_offset) {
return girara_list_nth(priv->links, index - priv->link_offset);
} else {
return NULL;