provide NAN define for MSVC older than VC12

This fixes a minor compile issue on VC11 and below
where source_impl.cc and sink_impl.cc use the float NAN define.
The patch simply defines the NAN macro conditionally,
in a common header (which seemed like the best place).
This commit is contained in:
Josh Blum 2015-12-06 17:10:25 -08:00
parent 9ceadfb645
commit c804460f5d
1 changed files with 6 additions and 0 deletions

View File

@ -18,4 +18,10 @@
#cmakedefine ENABLE_AIRSPY
#cmakedefine ENABLE_SOAPY
//provide NAN define for MSVC older than VC12
#if defined(_MSC_VER) && (_MSC_VER < 1800)
#include <limits>
#define NAN std::numeric_limits<double>::quiet_NaN()
#endif
#endif // CONFIG_H_IN