[poppler] [Fwd: Some poppler patches for Win32 portability]
tml at iki.fi
Mon Nov 26 15:02:25 PST 2007
> 1. It should be explicitly GetModuleFileNameA() - otherwise in Unicode
> build GetModeleFileName() will be resolved to GetModuleFileNameW() and
> bad things will happen.
OK, I didn't know that people were building it in "Unicode mode".
> DllMain could be
> removed and NULL passed to GetModuleFileNameA(). The difference is
> that it would return path of the exe that loaded dll, instead of dll
> itself (which, in most cases, will be the same).
Hmm. On end-user machines, probably yes. But on developer machines I
would say it could be quite common for an application installed in one
location to use a poppler library installed in another location. At
least that is how I work myself ;) So I guess some ifdefs are needed
then, #ifdef STATIC_COMPILATION or something like that.
> 3. It would be better to use GooString instead of a static buffer for
> dirname, to avoid possible buffer overruns.
Hmm, I don't know GooString;)
So, should I submit a new patch a'la above, or will you Krzysztof work on it?
More information about the poppler