libview: Fix crash in the accessible code when page cache text is NULL
If ev_page_cache_get_text()
returns NULL, it can crash both
get_character_count()
and get_substring()
implementations of
EvPageAccessible
, although it's an valid return value from the former.
Fix those to implementations to handle this edge case.
Unfortunately I'm afraid I can't share the PDF that revealed the issue for me, but the fix here is pretty straightforward.
Edited by Colomban Wendling