comipayan / googletest

Automatically exported from code.google.com/p/googletest
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Ensure that use of Microsoft specific functions are guarded by #ifdef _MSC_VER. #130

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Make sure that functions specific to Microsoft's runtime libraries are used
only inside #ifdef _MSC_VER section. Among others, such functions include
secure versions of CRT functions, like _snprintf_s.

Original issue reported on code.google.com by vladlosev on 11 Mar 2009 at 11:26

GoogleCodeExporter commented 9 years ago
More precisely, for _s functions, one should check the version of the compiler:
#if _MSC_VER >= 1400
// use _snprintf_s
#endif _MSC_VER >= 1400

Original comment by vladlosev on 11 Mar 2009 at 11:29

GoogleCodeExporter commented 9 years ago
Not worth it.  Will fix if this leads to a real problem.

Original comment by w...@google.com on 6 Mar 2010 at 6:15