Menu

#108 Visual Studio 2015 supports snprintf

None
closed
None
5
2018-07-31
2015-06-03
Anonymous
No

Visual Studio 2015 / CPT 14 supports C99 functions including snprintf. This means all the projects that do #define snprintf _snprintf will now throw errors.

The fix for this is to do:

1
2
3
#if _MSC_VER < 1900
   #define snprintf _snprintf
#endif

This needs to be done in 4 places:

./LibRawLite/dcraw/dcraw.c
./LibRawLite/internal/defines.h
./LibTIFF4/tif_config.h
./LibTIFF4/tif_config.vc.h

Discussion

  • Hervé Drolon

    Hervé Drolon - 2015-11-29

    Hi,

    Thanks for the patch, it is now merged with the CVS.

    Hervé

     
  • Hervé Drolon

    Hervé Drolon - 2015-11-29
    • status: open --> pending
    • assigned_to: Hervé Drolon
    • Group: -->
     
  • Anonymous

    Anonymous - 2016-11-07

    Hi!

    LibTIFF4/tif_config.h still has this problem. (VS "15" Preview 5, FreeImage 3.17.0).

    Have a nice day!

     
  • Hervé Drolon

    Hervé Drolon - 2018-07-31
    • status: pending --> closed
     
  • Hervé Drolon

    Hervé Drolon - 2018-07-31

    Fixed in release 3.18.0

     

Anonymous
Anonymous

Add attachments
Cancel





MongoDB Logo MongoDB