Fix error introduced when merging #264. (#286)

This commit is contained in:
RichardBarry 2021-03-20 12:59:51 -07:00 committed by GitHub
parent 6685c042cb
commit 6b72419c78
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -496,7 +496,7 @@ size_t xStreamBufferSpacesAvailable( StreamBufferHandle_t xStreamBuffer )
{ {
const StreamBuffer_t * const pxStreamBuffer = xStreamBuffer; const StreamBuffer_t * const pxStreamBuffer = xStreamBuffer;
size_t xSpace; size_t xSpace;
volatile size_t xOriginalTail; size_t xOriginalTail;
configASSERT( pxStreamBuffer ); configASSERT( pxStreamBuffer );
@ -726,7 +726,7 @@ static size_t prvWriteMessageToBuffer( StreamBuffer_t * const pxStreamBuffer,
{ {
size_t xNextHead = pxStreamBuffer->xHead; size_t xNextHead = pxStreamBuffer->xHead;
if( xDataLengthBytes != xRequiredSpace ) if( ( pxStreamBuffer->ucFlags & sbFLAGS_IS_MESSAGE_BUFFER ) != ( uint8_t ) 0 )
{ {
/* This is a message buffer, as opposed to a stream buffer. */ /* This is a message buffer, as opposed to a stream buffer. */