NamedDests in glib frontend are broken
Submitted by Jose Aliste
Assigned to poppler-bugs
Hi, currently, NamedDests in glib frontend are brokend. This is because in the pdf reference, Names trees can hold very wild strings, including byte strings, where the '\0' ending character assumption does not hold. Thus, a gchar * is not a good way of describing named destinations on the glib world. On test file, all the goostrings are alright, but when transforming these to gchar *, some of the byte strings have a '\0' before the end of the string.
This makes these PopplerDest objects unusable. We should get some more fancy API for that (Like using GBytes? and adding some methods to check if it is a proper string or so) or not to convert the name to gchar and use the PopplerDest object instead of the name on the find_link_dest and find_link_page funcs.