diff --git a/backend_disconnect_recover.c b/backend_disconnect_recover.c index 046a150..7c89df7 100644 --- a/backend_disconnect_recover.c +++ b/backend_disconnect_recover.c @@ -12,11 +12,20 @@ #include #include #include +#ifdef _WIN32 +#include +#define sleep(n) Sleep(n * 1000) +#else #include +#endif +#ifdef _MSC_VER +__declspec (noreturn) +#else __attribute__ ((cold)) __attribute__ ((noreturn)) __attribute__ ((format (printf, 1, 2))) +#endif static void panic(const char *format, ...) { va_list ap; va_start(ap, format); diff --git a/overflow.c b/overflow.c index 43b6d22..67947fe 100644 --- a/overflow.c +++ b/overflow.c @@ -12,7 +12,12 @@ #include #include #include +#ifdef _WIN32 +#include +#define sleep(n) Sleep(n * 1000) +#else #include +#endif static enum SoundIoFormat prioritized_formats[] = { SoundIoFormatFloat32NE, @@ -36,9 +41,13 @@ static enum SoundIoFormat prioritized_formats[] = { SoundIoFormatInvalid, }; +#ifdef _MSC_VER +__declspec (noreturn) +#else __attribute__ ((cold)) __attribute__ ((noreturn)) __attribute__ ((format (printf, 1, 2))) +#endif static void panic(const char *format, ...) { va_list ap; va_start(ap, format); diff --git a/underflow.c b/underflow.c index 083e92d..32907de 100644 --- a/underflow.c +++ b/underflow.c @@ -12,12 +12,21 @@ #include #include #include +#ifdef _WIN32 +#include +#define sleep(n) Sleep(n * 1000) +#else #include +#endif #include +#ifdef _MSC_VER +__declspec (noreturn) +#else __attribute__ ((cold)) __attribute__ ((noreturn)) __attribute__ ((format (printf, 1, 2))) +#endif static void panic(const char *format, ...) { va_list ap; va_start(ap, format);