Skip to content

Commit 1dc4125

Browse files
committed
Fix builds for MSVC 2003 (#4761)
1 parent 707ef28 commit 1dc4125

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

mapdebug.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -370,3 +370,12 @@ void msDebug( const char * pszFormat, ... )
370370

371371
}
372372

373+
374+
/* msDebug2()
375+
**
376+
** Variadic function with no operation
377+
**
378+
*/
379+
void msDebug2( int level, ... )
380+
{
381+
}

mapserver.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -511,10 +511,14 @@ extern "C" {
511511
enum MS_GEOS_OPERATOR {MS_GEOS_EQUALS, MS_GEOS_DISJOINT, MS_GEOS_TOUCHES, MS_GEOS_OVERLAPS, MS_GEOS_CROSSES, MS_GEOS_INTERSECTS, MS_GEOS_WITHIN, MS_GEOS_CONTAINS, MS_GEOS_BEYOND, MS_GEOS_DWITHIN};
512512
#define MS_FILE_DEFAULT MS_FILE_MAP
513513

514+
#if defined(_MSC_VER) && (_MSC_VER <= 1310)
515+
#define MS_DEBUG msDebug2
516+
#else
514517
#ifdef USE_EXTENDED_DEBUG
515518
#define MS_DEBUG(level,elt,fmt, ...) if((elt)->debug >= (level)) msDebug(fmt,##__VA_ARGS__)
516519
#else
517-
#define MS_DEBUG(level,elt,fmt, ...) /* no-op */
520+
#define MS_DEBUG(level,elt,fmt, ...) /* no-op */
521+
#endif
518522
#endif
519523

520524
/* coordinate to pixel simplification modes, used in msTransformShape */

0 commit comments

Comments
 (0)