diff options
Diffstat (limited to 'nuttx/sched/env_getenv.c')
-rw-r--r-- | nuttx/sched/env_getenv.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/nuttx/sched/env_getenv.c b/nuttx/sched/env_getenv.c index be0a83d2e..ee8d798b1 100644 --- a/nuttx/sched/env_getenv.c +++ b/nuttx/sched/env_getenv.c @@ -2,7 +2,7 @@ * env_getenv.c * * Copyright (C) 2007, 2008 Gregory Nutt. All rights reserved. - * Author: Gregory Nutt <spudmonkey@racsa.co.cr> + * Author: Gregory Nutt <gnutt@nuttx.org> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -58,7 +58,7 @@ ****************************************************************************/ /**************************************************************************** - * Function: getenv + * Name: getenv * * Description: * The getenv() function searches the environment list for a string that @@ -91,7 +91,6 @@ FAR char *getenv(const char *name) goto errout; } - /* Get a reference to the thread-private environ in the TCB.*/ sched_lock(); @@ -126,7 +125,7 @@ FAR char *getenv(const char *name) errout_with_lock: sched_unlock(); errout: - *get_errno_ptr() = ret; + set_errno(ret); return NULL; } |