summaryrefslogtreecommitdiff
path: root/nuttx/libc
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2013-12-30 14:09:58 -0600
committerGregory Nutt <gnutt@nuttx.org>2013-12-30 14:09:58 -0600
commitef06e94a13aa48b0f9c1dde244ee3d4299a9156c (patch)
tree255ae18810c3c4339ce91ee019c4cbac021f2655 /nuttx/libc
parentfd95f9ae75acb674be870e3a92c05816bcbbd819 (diff)
downloadpx4-nuttx-ef06e94a13aa48b0f9c1dde244ee3d4299a9156c.tar.gz
px4-nuttx-ef06e94a13aa48b0f9c1dde244ee3d4299a9156c.tar.bz2
px4-nuttx-ef06e94a13aa48b0f9c1dde244ee3d4299a9156c.zip
Fix some minor kernel mose NxWM build issues
Diffstat (limited to 'nuttx/libc')
-rw-r--r--nuttx/libc/wqueue/work_usrstart.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/nuttx/libc/wqueue/work_usrstart.c b/nuttx/libc/wqueue/work_usrstart.c
index 5b51931c6..696bf04aa 100644
--- a/nuttx/libc/wqueue/work_usrstart.c
+++ b/nuttx/libc/wqueue/work_usrstart.c
@@ -88,10 +88,6 @@
int work_usrstart(void)
{
- int errcode;
-
- DEBUGASSERT(g_usrwork[USRWORK] == NULL);
-
/* Start a user-mode worker thread for use by applications. */
svdbg("Starting user-mode worker thread\n");
@@ -102,10 +98,12 @@ int work_usrstart(void)
(main_t)work_usrthread,
(FAR char * const *)NULL);
- errcode = errno;
- ASSERT(g_usrwork[USRWORK].pid > 0);
+ DEBUGASSERT(g_usrwork[USRWORK].pid > 0);
if (g_usrwork[USRWORK].pid < 0)
{
+ int errcode = errno;
+ DEBUGASSERT(errcode > 0);
+
sdbg("task_create failed: %d\n", errcode);
return -errcode;
}