Skip to content
Snippets Groups Projects
Commit e323b2f8 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Don't use the deprecated pthread_yield() function

Per https://man7.org/linux/man-pages/man3/pthread_yield.3.html
       This call is nonstandard, but present on several other systems.
       Use the standardized sched_yield(2) instead.

Should fix #299.
parent f8d8b430
No related branches found
No related tags found
No related merge requests found
......@@ -304,8 +304,6 @@ DLLEXPORT int get_errno(void);
#if defined(XPDEV_THREAD_SAFE)
#if defined(__FreeBSD__)
#define MAYBE_YIELD() pthread_yield()
#elif defined(_PTH_PTHREAD_H_)
#define MAYBE_YIELD() pth_yield(NULL)
#elif defined(_POSIX_PRIORITY_SCHEDULING)
#define MAYBE_YIELD() sched_yield()
#else
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment