include/nuttx/semaphore.h: Fix broken macros

This commit is contained in:
Gregory Nutt
2016-11-03 12:49:44 -06:00
parent 1da3a5fa61
commit 4c8ec0d2ca
6 changed files with 17 additions and 26 deletions
-8
View File
@@ -160,11 +160,7 @@ int sem_reset(FAR sem_t *sem, int16_t count);
*
****************************************************************************/
#ifdef CONFIG_PRIORITY_INHERITANCE
int sem_getprotocol(FAR sem_t *sem, FAR int *protocol);
#else
# define sem_getprotocol(s,p) do { *(p) == SEM_PRIO_NONE); } while (0)
#endif
/****************************************************************************
* Function: sem_setprotocol
@@ -202,11 +198,7 @@ int sem_getprotocol(FAR sem_t *sem, FAR int *protocol);
*
****************************************************************************/
#ifdef CONFIG_PRIORITY_INHERITANCE
int sem_setprotocol(FAR sem_t *sem, int protocol);
#else
# define sem_setprotocol(s,p) ((p) == SEM_PRIO_NONE ? 0 : -ENOSYS);
#endif
#undef EXTERN
#ifdef __cplusplus