Fix more issues detected by CppCheck tool
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3264 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
parent
7d12e1fd04
commit
78d6af1190
@ -1435,3 +1435,5 @@
|
||||
class driver.
|
||||
* configs/olimex-lpc1766stk/hidkbd - Added a configuration to build the
|
||||
USB host HID keyboard class driver test for the LPC17xx.
|
||||
* Ran the tool CppCheck (http://sourceforge.net/apps/mediawiki/cppcheck) and
|
||||
fixed several errors in the code identified by the tool.
|
@ -8,7 +8,7 @@
|
||||
<tr align="center" bgcolor="#e4e4e4">
|
||||
<td>
|
||||
<h1><big><font color="#3c34ec"><i>NuttX RTOS</i></font></big></h1>
|
||||
<p>Last Updated: January 18, 2011</p>
|
||||
<p>Last Updated: January 19, 2011</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@ -2116,6 +2116,8 @@ nuttx-5.17 2011-xx-xx Gregory Nutt <spudmonkey@racsa.co.cr>
|
||||
class driver.
|
||||
* configs/olimex-lpc1766stk/hidkbd - Added a configuration to build the
|
||||
USB host HID keyboard class driver test for the LPC17xx.
|
||||
* Ran the tool CppCheck (http://sourceforge.net/apps/mediawiki/cppcheck) and
|
||||
fixed several errors in the code identified by the tool.
|
||||
|
||||
pascal-2.1 2010-xx-xx Gregory Nutt <spudmonkey@racsa.co.cr>
|
||||
|
||||
|
@ -614,7 +614,7 @@ static inline int usbhost_cfgdesc(FAR struct usbhost_state_s *priv,
|
||||
|
||||
static inline int usbhost_devinit(FAR struct usbhost_state_s *priv)
|
||||
{
|
||||
int ret;
|
||||
int ret = OK;
|
||||
|
||||
/* Set aside a transfer buffer for exclusive use by the class driver */
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
/************************************************************************
|
||||
* sched/mq_initialize.c
|
||||
*
|
||||
* Copyright (C) 2007, 2009 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2007, 2009, 2011 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <spudmonkey@racsa.co.cr>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -210,8 +210,8 @@ void mq_initialize(void)
|
||||
* Function: mq_desblockalloc
|
||||
*
|
||||
* Description:
|
||||
* Allocate a block of message descriptors and place them
|
||||
* on the free list.
|
||||
* Allocate a block of message descriptors and place them on the free
|
||||
* list.
|
||||
*
|
||||
* Inputs:
|
||||
* None
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* sched/pthread_mutexinit.c
|
||||
*
|
||||
* Copyright (C) 2007-2009 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2007-2009, 2011 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <spudmonkey@racsa.co.cr>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -124,14 +124,14 @@ int pthread_mutex_init(FAR pthread_mutex_t *mutex, FAR pthread_mutexattr_t *attr
|
||||
{
|
||||
ret = EINVAL;
|
||||
}
|
||||
}
|
||||
|
||||
/* Set up attributes unique to the mutex type */
|
||||
/* Set up attributes unique to the mutex type */
|
||||
|
||||
#ifdef CONFIG_MUTEX_TYPES
|
||||
mutex->type = type;
|
||||
mutex->nlocks = 0;
|
||||
mutex->type = type;
|
||||
mutex->nlocks = 0;
|
||||
#endif
|
||||
}
|
||||
|
||||
sdbg("Returning %d\n", ret);
|
||||
return ret;
|
||||
|
Loading…
Reference in New Issue
Block a user