porting/npl/linux: Replace pthread_yield() with sched_yield()

Per `pthread_yield(3)`:
```
  This call is nonstandard, but present on several other systems.
  Use the standardized sched_yield(2) instead.
```
This commit is contained in:
Deomid "rojer" Ryabkov
2023-07-20 18:47:20 +02:00
committed by Andrzej Kaczmarek
parent 18738b2743
commit 188256f1ef
+3 -1
View File
@@ -17,6 +17,8 @@
* under the License.
*/
#include <sched.h>
#include "os/os.h"
#include "nimble/nimble_npl.h"
@@ -106,7 +108,7 @@ bool ble_npl_os_started(void)
void ble_npl_task_yield(void)
{
pthread_yield();
sched_yield();
}
#ifdef __cplusplus