In fofi/FoFiIdentifier.cc there are several internal classes MemReader, FileReader etc. These are in the global namespace. Incidentally, in our code there is a class FileReader, too. It also has a constructor FileReaader(FILE*). Guess which code gets executed in FoFiIdentifier.cc ... the wrong one. (Yes, FileReader is a rather dangerous name, and no, my FileReader is in the global namespace as well....) This leads to a crash when opening a pdf containing fonts that need to be looked up. Trivial solution: wrap the internal classes with an anonymous namespace. Or with namespace poppler. As the class is internal to this file, this won't cause problems. Another good idea might be to introduce symbol (in)visiblity... Best regards and thank you for a really helpful library.
Any chance you would send a patch?
Created attachment 80563 [details] [review] patch (wrapping classes in anonymous namespace) just wraps the internal classes in namespace { ... }. (Sorry for the delay, I was offline in holiday.)
Will be in poppler 0.24.0
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.