[Poppler-bugs] [Bug 26802] Fix some msvc warnings

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Wed Mar 3 09:51:39 PST 2010


http://bugs.freedesktop.org/show_bug.cgi?id=26802





--- Comment #4 from Christian Ehrlicher <ch.ehrlicher at gmx.de>  2010-03-03 09:51:38 PST ---
It would also be nice to add
if(msvc)
   add_definitions( -D_CRT_SECURE_NO_DEPRECATE
                    -D_CRT_NONSTDC_NO_DEPRECATE
                  )
endif(msvc)

to net get warnigns about 'deprecated' functions like strdup().

The fix for GlobalParams.cc is easy - just remove the cast to 'const unsigned
char*' - 'unsigned char*' is enough. Looks like ms has an overloaded _mbsrchr()
which takes and returns a const usnigned char* ...

Now I'm stuck at SplashOutputDev.cc:1987 - finite() isn't available on win. You
have to use _finite()
(http://msdn.microsoft.com/de-de/library/sb8es7a8(VS.80).aspx) -->

#ifdef _MSC_VER
#include <float.h>
inline double isfinite(double x) { return _finite(x); }
#endif


-- 
Configure bugmail: http://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the Poppler-bugs mailing list