Correct some bad parameter checking

git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5197 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
patacongo
2012-09-27 03:13:50 +00:00
parent 41396d5960
commit c48a617cd2
6 changed files with 14 additions and 9 deletions
+2 -2
View File
@@ -111,8 +111,8 @@ int nx_block(NXWINDOW hwnd, FAR void *arg)
#ifdef CONFIG_DEBUG
if (!hwnd)
{
errno = EINVAL;
return NULL;
set_errno(EINVAL);
return ERROR;
}
#endif
+2 -2
View File
@@ -93,9 +93,9 @@ int nxmu_sendclient(FAR struct nxfe_conn_s *conn, FAR const void *msg,
/* Sanity checking */
#ifdef CONFIG_DEBUG
if (!conn || conn->swrmq)
if (!conn || !conn->swrmq)
{
errno = EINVAL;
set_errno(EINVAL);
return ERROR;
}
#endif
+2 -2
View File
@@ -93,9 +93,9 @@ int nxmu_sendserver(FAR struct nxfe_conn_s *conn, FAR const void *msg,
/* Sanity checking */
#ifdef CONFIG_DEBUG
if (!conn || conn->cwrmq)
if (!conn || !conn->cwrmq)
{
errno = EINVAL;
set_errno(EINVAL);
return ERROR;
}
#endif