mirror of
https://github.com/apache/nuttx.git
synced 2026-06-04 23:03:27 +08:00
Fix wait loop and void cast (#24)
* Simplify EINTR/ECANCEL error handling 1. Add semaphore uninterruptible wait function 2 .Replace semaphore wait loop with a single uninterruptible wait 3. Replace all sem_xxx to nxsem_xxx * Unify the void cast usage 1. Remove void cast for function because many place ignore the returned value witout cast 2. Replace void cast for variable with UNUSED macro
This commit is contained in:
@@ -143,7 +143,7 @@ int setenv(FAR const char *name, FAR const char *value, int overwrite)
|
||||
* the environment buffer; this will happen below.
|
||||
*/
|
||||
|
||||
(void)env_removevar(group, pvar);
|
||||
env_removevar(group, pvar);
|
||||
}
|
||||
|
||||
/* Get the size of the new name=value string. The +2 is for the '=' and for
|
||||
|
||||
@@ -90,7 +90,7 @@ int unsetenv(FAR const char *name)
|
||||
{
|
||||
/* It does! Remove the name=value pair from the environment. */
|
||||
|
||||
(void)env_removevar(group, pvar);
|
||||
env_removevar(group, pvar);
|
||||
|
||||
/* Reallocate the new environment buffer */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user