Fix pthread_setname_np conflicts for Mac OS X (#2263)

This commit is contained in:
HooperFly
2018-05-11 01:49:52 -07:00
committed by Gautier Hattenberger
parent 1d66b19adc
commit c108f707f6
3 changed files with 3 additions and 3 deletions
@@ -103,9 +103,7 @@ void sys_time_arch_init(void)
perror("Could not setup sys_time_thread");
return;
}
#ifndef MACOSX
pthread_setname_np(tid, "pprz_sys_time_thread");
#endif
}
static void sys_tick_handler(void)
@@ -60,7 +60,7 @@ void uart_arch_init(void)
fprintf(stderr, "uart_arch_init: Could not create UART reading thread.\n");
return;
}
#ifndef MACOSX
#ifndef __APPLE__
pthread_setname_np(tid, "pprz_uart_thread");
#endif
}
@@ -59,7 +59,9 @@ void udp_arch_init(void)
fprintf(stderr, "udp_arch_init: Could not create UDP reading thread.\n");
return;
}
#ifndef __APPLE__
pthread_setname_np(tid, "pprz_udp_thread");
#endif
}
/**