#include <windows.h>
#include <process.h>
-typedef struct {
+#include "libavutil/internal.h"
+#include "libavutil/mem.h"
+
+typedef struct pthread_t {
void *handle;
void *(*func)(void* arg);
void *arg;
/* This is the CONDITIONAL_VARIABLE typedef for using Window's native
* conditional variables on kernels 6.0+.
* MinGW does not currently have this typedef. */
-typedef struct {
+typedef struct pthread_cond_t {
void *ptr;
} pthread_cond_t;
/* for pre-Windows 6.0 platforms we need to define and use our own condition
* variable and api */
-typedef struct {
+typedef struct win32_cond_t {
pthread_mutex_t mtx_broadcast;
pthread_mutex_t mtx_waiter_count;
volatile int waiter_count;