#define AUBIO_DBG _AUBIO_DBG
#else
// disable debug output
-#define AUBIO_DBG(format, args...)
+#ifdef HAVE_C99_VARARGS_MACROS
+#define AUBIO_DBG(...) {}
+#else
+#define AUBIO_DBG(format, args...) {}
+#endif
#endif
#define AUBIO_ERROR AUBIO_ERR
#define AUBIO_QUIT(_s) exit(_s)
-#define AUBIO_SPRINTF sprintf
+#define AUBIO_SNPRINTF snprintf
#define AUBIO_MAX_SAMPLERATE (192000*8)
#define AUBIO_MAX_CHANNELS 1024
#define isnan _isnan
#endif
-#if !defined(_MSC_VER)
+#if !defined(_WIN32)
#define AUBIO_STRERROR(errno,buf,len) strerror_r(errno, buf, len)
#else
#define AUBIO_STRERROR(errno,buf,len) strerror_s(buf, len, errno)