mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-10-23 21:27:45 -04:00
Sync FreeRTOS-Labs -CLI -TCP -Trace with the version in FreeRTOS-Plus.
Projects under FreeRTOS-Labs directory are in beta, developers updating projects please make sure you are using the correct version of -CLI -TCP -Trace. If you must edit -CLI -TCP and -Trace, please ensure the copies are synced.
This commit is contained in:
parent
ec6f3d77c3
commit
9fdfbf33e9
58 changed files with 4129 additions and 4415 deletions
|
|
@ -1,6 +1,6 @@
|
|||
/*
|
||||
* FreeRTOS+TCP 191100 experimental
|
||||
* Copyright (C) 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
||||
* FreeRTOS+TCP V2.2.0
|
||||
* Copyright (C) 2017 Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
* this software and associated documentation files (the "Software"), to deal in
|
||||
|
|
@ -675,17 +675,17 @@ const int32_t l500ms = 500;
|
|||
|
||||
#if( ipconfigUSE_TCP_WIN == 1 )
|
||||
|
||||
void vTCPSegmentCleanup( void )
|
||||
{
|
||||
/* Free and clear the TCP segments pointer. This function should only be called
|
||||
* once FreeRTOS+TCP will no longer be used. No thread-safety is provided for this
|
||||
* function. */
|
||||
if( xTCPSegments != NULL )
|
||||
{
|
||||
vPortFreeLarge( xTCPSegments );
|
||||
xTCPSegments = NULL;
|
||||
}
|
||||
}
|
||||
void vTCPSegmentCleanup( void )
|
||||
{
|
||||
/* Free and clear the TCP segments pointer. This function should only be called
|
||||
* once FreeRTOS+TCP will no longer be used. No thread-safety is provided for this
|
||||
* function. */
|
||||
if( xTCPSegments != NULL )
|
||||
{
|
||||
vPortFreeLarge( xTCPSegments );
|
||||
xTCPSegments = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* ipconfgiUSE_TCP_WIN == 1 */
|
||||
/*-----------------------------------------------------------*/
|
||||
|
|
@ -805,20 +805,20 @@ const int32_t l500ms = 500;
|
|||
{
|
||||
ulSavedSequenceNumber = ulCurrentSequenceNumber;
|
||||
|
||||
/* Clean up all sequence received between ulSequenceNumber and ulSequenceNumber + ulLength since they are duplicated.
|
||||
If the server is forced to retransmit packets several time in a row it might send a batch of concatenated packet for speed.
|
||||
So we cannot rely on the packets between ulSequenceNumber and ulSequenceNumber + ulLength to be sequential and it is better to just
|
||||
clean them out. */
|
||||
do
|
||||
{
|
||||
pxFound = xTCPWindowRxConfirm( pxWindow, ulSequenceNumber, ulLength );
|
||||
/* Clean up all sequence received between ulSequenceNumber and ulSequenceNumber + ulLength since they are duplicated.
|
||||
If the server is forced to retransmit packets several time in a row it might send a batch of concatenated packet for speed.
|
||||
So we cannot rely on the packets between ulSequenceNumber and ulSequenceNumber + ulLength to be sequential and it is better to just
|
||||
clean them out. */
|
||||
do
|
||||
{
|
||||
pxFound = xTCPWindowRxConfirm( pxWindow, ulSequenceNumber, ulLength );
|
||||
|
||||
if ( pxFound != NULL )
|
||||
{
|
||||
/* Remove it because it will be passed to user directly. */
|
||||
vTCPWindowFree( pxFound );
|
||||
}
|
||||
} while ( pxFound );
|
||||
if ( pxFound != NULL )
|
||||
{
|
||||
/* Remove it because it will be passed to user directly. */
|
||||
vTCPWindowFree( pxFound );
|
||||
}
|
||||
} while ( pxFound );
|
||||
|
||||
/* Check for following segments that are already in the
|
||||
queue and increment ulCurrentSequenceNumber. */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue