Fix MISRA_C_2012 rule 20.7 violation (#843)
* Wrap macro parameter expansion by parentheses * Update parentheses in SMP macro definition --------- Co-authored-by: Soren Ptak <ptaksoren@gmail.com> Co-authored-by: Monika Singh <moninom@amazon.com> Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
This commit is contained in:
@ -153,16 +153,16 @@
|
||||
* invoke the callback else use the send complete macro which is provided by default for all instances.
|
||||
*/
|
||||
#if ( configUSE_SB_COMPLETED_CALLBACK == 1 )
|
||||
#define prvSEND_COMPLETED( pxStreamBuffer ) \
|
||||
do { \
|
||||
if( ( pxStreamBuffer )->pxSendCompletedCallback != NULL ) \
|
||||
{ \
|
||||
pxStreamBuffer->pxSendCompletedCallback( ( pxStreamBuffer ), pdFALSE, NULL ); \
|
||||
} \
|
||||
else \
|
||||
{ \
|
||||
sbSEND_COMPLETED( ( pxStreamBuffer ) ); \
|
||||
} \
|
||||
#define prvSEND_COMPLETED( pxStreamBuffer ) \
|
||||
do { \
|
||||
if( ( pxStreamBuffer )->pxSendCompletedCallback != NULL ) \
|
||||
{ \
|
||||
( pxStreamBuffer )->pxSendCompletedCallback( ( pxStreamBuffer ), pdFALSE, NULL ); \
|
||||
} \
|
||||
else \
|
||||
{ \
|
||||
sbSEND_COMPLETED( ( pxStreamBuffer ) ); \
|
||||
} \
|
||||
} while( 0 )
|
||||
#else /* if ( configUSE_SB_COMPLETED_CALLBACK == 1 ) */
|
||||
#define prvSEND_COMPLETED( pxStreamBuffer ) sbSEND_COMPLETED( ( pxStreamBuffer ) )
|
||||
|
Reference in New Issue
Block a user