!6583 vtp crash bugfix

Merge pull request !6583 from Agrant/OpenHarmony-5.0-Beta1
This commit is contained in:
openharmony_ci 2024-06-14 13:31:42 +00:00 committed by Gitee
commit 7cd0806deb
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
3 changed files with 8 additions and 7 deletions

View File

@ -388,7 +388,7 @@ typedef enum InnerfillpClientfourhandshakestateEnum {
static __inline FILLP_INT FillpNumIsbigger(FILLP_UINT32 value1, FILLP_UINT32 value2)
{
return ((FILLP_INT32)(value1 - value2)) > 0;
return value1 > value2;
}
void FillpSendConnConfirmAck(struct FillpPcb *pcb);

View File

@ -43,17 +43,18 @@ Return : NA
******************************************************************************/
static void FillpCleanSedata(void *ptr, size_t len, struct SpungeInstance *pcbInst)
{
FILLP_UINT8 *pptr = ptr;
size_t loop = len;
size_t ctr = pcbInst->cleanseDataCtr;
if (ptr == FILLP_NULL_PTR) {
return;
}
while (loop--) {
FILLP_UINT8 *pptr = ptr;
size_t loop = len;
size_t ctr = pcbInst->cleanseDataCtr;
while (loop > 0) {
*(pptr++) = (FILLP_UINT8)ctr;
ctr += (CSE_DATA_ONE_PAR + ((size_t)(uintptr_t)pptr & 0xF));
loop--;
}
pptr = FILLP_MEMCHR(ptr, (FILLP_UINT8)ctr, len);

View File

@ -354,7 +354,7 @@ FILLP_BOOL SpungeConnCheckUnsendBoxEmpty(struct FtNetconn *conn)
con = unsendBox->ring.cons.head + 1;
prod = unsendBox->ring.prod.tail;
while (((FILLP_LLONG)(prod - con)) >= 0) {
while (prod >= con) {
data = unsendBox->ring.ringCache[con % unsendBox->ring.size];
con++;