easy_lock: check for HAVE_STDATOMIC_H as well

The check for `HAVE_STDATOMIC_H` looks to see if the `stdatomic.h`
header is present.

Closes #9755
This commit is contained in:
Don Olmstead 2022-10-17 16:58:50 -07:00 committed by Daniel Stenberg
parent 4a5a270699
commit 2e69df0a26
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2

View File

@ -47,7 +47,7 @@ typedef PVOID SRWLOCK, *PSRWLOCK;
#define curl_simple_lock_lock(m) AcquireSRWLockExclusive(m)
#define curl_simple_lock_unlock(m) ReleaseSRWLockExclusive(m)
#elif defined (HAVE_ATOMIC)
#elif defined(HAVE_ATOMIC) && defined(HAVE_STDATOMIC_H)
#include <stdatomic.h>
#if defined(HAVE_SCHED_YIELD)
#include <sched.h>