fix:告警清理
Signed-off-by: liuwenxin <liuwenxin11@huawei.com>
This commit is contained in:
parent
972d765c6e
commit
8b54493665
|
@ -91,7 +91,6 @@ LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis007, Function | MediumTest | Level1)
|
|||
{
|
||||
osMessageQueueId_t msgQueueId;
|
||||
osMessageQueueAttr_t attr = {0};
|
||||
CHAR staticBuff[STATCI_BUFF_SIZE] = {0};
|
||||
CHAR strbuff[] = "hello world";
|
||||
CHAR *name = NULL;
|
||||
INT32 ret;
|
||||
|
@ -112,6 +111,7 @@ LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis007, Function | MediumTest | Level1)
|
|||
ICUNIT_ASSERT_EQUAL(name, NULL, name);
|
||||
|
||||
#if (LOSCFG_BASE_IPC_QUEUE_STATIC == 1)
|
||||
CHAR staticBuff[STATCI_BUFF_SIZE] = {0};
|
||||
attr.mq_mem = staticBuff;
|
||||
attr.mq_size = STATCI_BUFF_SIZE;
|
||||
msgQueueId = osMessageQueueNew(1, STATCI_BUFF_SIZE, &attr);
|
||||
|
@ -239,8 +239,6 @@ LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis006, Function | MediumTest | Level1)
|
|||
LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis005, Function | MediumTest | Level1)
|
||||
{
|
||||
osMessageQueueId_t msgQueueId;
|
||||
osMessageQueueAttr_t attr = {0};
|
||||
CHAR staticBuff[STATCI_BUFF_SIZE] = {0};
|
||||
CHAR strbuff[] = "hello world";
|
||||
CHAR data[STATCI_BUFF_SIZE] = {0};
|
||||
INT32 ret;
|
||||
|
@ -272,6 +270,8 @@ LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis005, Function | MediumTest | Level1)
|
|||
|
||||
#if (LOSCFG_BASE_IPC_QUEUE_STATIC == 1)
|
||||
/* static test */
|
||||
osMessageQueueAttr_t attr = {0};
|
||||
CHAR staticBuff[STATCI_BUFF_SIZE] = {0};
|
||||
attr.mq_mem = staticBuff;
|
||||
attr.mq_size = STATCI_BUFF_SIZE;
|
||||
msgQueueId = osMessageQueueNew(1, STATCI_BUFF_SIZE, &attr);
|
||||
|
@ -311,8 +311,6 @@ EXIT:
|
|||
LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis004, Function | MediumTest | Level1)
|
||||
{
|
||||
osMessageQueueId_t msgQueueId;
|
||||
osMessageQueueAttr_t attr = {0};
|
||||
CHAR staticBuff[STATCI_BUFF_SIZE] = {0};
|
||||
CHAR strbuff[] = "hello world";
|
||||
CHAR data[STATCI_BUFF_SIZE] = {0};
|
||||
INT32 ret;
|
||||
|
@ -335,6 +333,8 @@ LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis004, Function | MediumTest | Level1)
|
|||
|
||||
#if (LOSCFG_BASE_IPC_QUEUE_STATIC == 1)
|
||||
/* static test */
|
||||
osMessageQueueAttr_t attr = {0};
|
||||
CHAR staticBuff[STATCI_BUFF_SIZE] = {0};
|
||||
attr.mq_mem = staticBuff;
|
||||
attr.mq_size = strlen(strbuff) + 1;
|
||||
msgQueueId = osMessageQueueNew(1, strlen(strbuff), &attr);
|
||||
|
@ -373,8 +373,6 @@ EXIT:
|
|||
LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis003, Function | MediumTest | Level1)
|
||||
{
|
||||
osMessageQueueId_t msgQueueId;
|
||||
osMessageQueueAttr_t attr = {0};
|
||||
CHAR staticBuff[STATCI_BUFF_SIZE] = {0};
|
||||
CHAR strbuff[] = "hello world";
|
||||
|
||||
/* dynmic test */
|
||||
|
@ -386,6 +384,8 @@ LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis003, Function | MediumTest | Level1)
|
|||
|
||||
#if (LOSCFG_BASE_IPC_QUEUE_STATIC == 1)
|
||||
/* static test */
|
||||
osMessageQueueAttr_t attr = {0};
|
||||
CHAR staticBuff[STATCI_BUFF_SIZE] = {0};
|
||||
attr.mq_mem = staticBuff;
|
||||
attr.mq_size = STATCI_BUFF_SIZE;
|
||||
msgQueueId = osMessageQueueNew(0, strlen(strbuff), &attr);
|
||||
|
@ -417,8 +417,6 @@ LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis003, Function | MediumTest | Level1)
|
|||
LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis002, Function | MediumTest | Level1)
|
||||
{
|
||||
osMessageQueueId_t msgQueueId;
|
||||
osMessageQueueAttr_t attr = {0};
|
||||
CHAR staticBuff[STATCI_BUFF_SIZE] = {0};
|
||||
CHAR strbuff[] = "hello world";
|
||||
INT32 ret;
|
||||
|
||||
|
@ -434,6 +432,8 @@ LITE_TEST_CASE(CmsisFuncTestSuite, TestCmsis002, Function | MediumTest | Level1)
|
|||
|
||||
#if (LOSCFG_BASE_IPC_QUEUE_STATIC == 1)
|
||||
/* static test */
|
||||
osMessageQueueAttr_t attr = {0};
|
||||
CHAR staticBuff[STATCI_BUFF_SIZE] = {0};
|
||||
attr.mq_mem = staticBuff;
|
||||
attr.mq_size = STATCI_BUFF_SIZE;
|
||||
msgQueueId = osMessageQueueNew(1, STATCI_BUFF_SIZE, &attr);
|
||||
|
|
|
@ -62,9 +62,9 @@ static UINT32 TestCase(VOID)
|
|||
ICUNIT_ASSERT_EQUAL(ret, LOS_OK, ret);
|
||||
LOS_TaskDelay(20); // delay 20 ticks.
|
||||
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 1, g_testCount, EXIT);
|
||||
ICUNIT_GOTO_EQUAL(g_testAtomicID05, TEST_LOOP, g_testAtomicID05, EXIT);
|
||||
EXIT:
|
||||
ICUNIT_ASSERT_EQUAL(g_testCount, 1, g_testCount);
|
||||
ICUNIT_ASSERT_EQUAL(g_testAtomicID05, TEST_LOOP, g_testAtomicID05);
|
||||
|
||||
return LOS_OK;
|
||||
}
|
||||
|
||||
|
|
|
@ -232,8 +232,8 @@ static UINT32 TestCase(VOID)
|
|||
ICUNIT_ASSERT_EQUAL(ret, LOS_OK, ret);
|
||||
LOS_TaskDelay(20); // delay 20 ticks.
|
||||
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 1, g_testCount, EXIT);
|
||||
EXIT:
|
||||
ICUNIT_ASSERT_EQUAL(g_testCount, 1, g_testCount);
|
||||
|
||||
return LOS_OK;
|
||||
}
|
||||
|
||||
|
|
|
@ -36,7 +36,6 @@ STATIC UINT32 TestCase(VOID)
|
|||
VOID *handle = NULL;
|
||||
CHAR *dsoNeedOthers = DSO_FULL_PATH("Align4_dynamic_need_others.so");
|
||||
CHAR *dsoWithoutPIC = DSO_FULL_PATH("Align4_dynamic_nopic.so");
|
||||
INT32 ret;
|
||||
|
||||
handle = (VOID *)LOS_SoLoad(dsoNeedOthers, NULL);
|
||||
ICUNIT_ASSERT_EQUAL(handle, NULL, handle);
|
||||
|
|
|
@ -36,7 +36,6 @@ STATIC UINT32 TestCase(VOID)
|
|||
VOID *handle = NULL;
|
||||
VOID (*func)(INT32, INT32) = NULL;
|
||||
CHAR *dsoName = DSO_FULL_PATH("Align4_dynamic_stdlib.so");
|
||||
INT32 ret;
|
||||
|
||||
handle = (VOID *)LOS_SoLoad(dsoName, NULL);
|
||||
ICUNIT_ASSERT_EQUAL(handle, NULL, handle);
|
||||
|
|
|
@ -74,7 +74,7 @@ static UINT32 Testcase(VOID)
|
|||
LOS_EventInit(&g_pevent);
|
||||
|
||||
ret = LOS_TaskCreate(&g_testTaskID01, &task1);
|
||||
ICUNIT_GOTO_EQUAL(ret, LOS_OK, ret, EXIT);
|
||||
ICUNIT_ASSERT_EQUAL(ret, LOS_OK, ret);
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 3, g_testCount, EXIT); // 3, Here, assert that g_testCount is equal to 3.
|
||||
|
||||
g_testCount++;
|
||||
|
@ -84,7 +84,6 @@ static UINT32 Testcase(VOID)
|
|||
ICUNIT_GOTO_EQUAL(g_testCount, 4, g_testCount, EXIT1); // 4, Here, assert that g_testCount is equal to 4.
|
||||
|
||||
EXIT1:
|
||||
|
||||
ret = LOS_EventClear(&g_pevent, 0);
|
||||
ICUNIT_ASSERT_EQUAL(ret, LOS_OK, ret);
|
||||
|
||||
|
|
|
@ -84,7 +84,7 @@ static UINT32 Testcase(VOID)
|
|||
LOS_EventInit(&g_pevent);
|
||||
|
||||
ret = LOS_TaskCreate(&g_testTaskID01, &task1);
|
||||
ICUNIT_GOTO_EQUAL(ret, LOS_OK, ret, EXIT);
|
||||
ICUNIT_ASSERT_EQUAL(ret, LOS_OK, ret);
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 1, g_testCount, EXIT);
|
||||
|
||||
g_testCount++;
|
||||
|
|
|
@ -87,7 +87,7 @@ static UINT32 Testcase(VOID)
|
|||
ret = LOS_EventWrite(&g_pevent, 0x11);
|
||||
ICUNIT_GOTO_EQUAL(ret, LOS_OK, ret, EXIT1);
|
||||
|
||||
ret = LOS_TaskResume(g_testTaskID01);
|
||||
(VOID)LOS_TaskResume(g_testTaskID01);
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 5, g_testCount, EXIT1); // 5, Here, assert that g_testCount is equal to 5.
|
||||
|
||||
EXIT1:
|
||||
|
|
|
@ -90,7 +90,7 @@ static UINT32 Testcase(VOID)
|
|||
LOS_EventInit(&g_pevent);
|
||||
|
||||
ret = LOS_TaskCreate(&g_testTaskID01, &task1);
|
||||
ICUNIT_GOTO_EQUAL(ret, LOS_OK, ret, EXIT);
|
||||
ICUNIT_ASSERT_EQUAL(ret, LOS_OK, ret);
|
||||
|
||||
ICUNIT_ASSERT_EQUAL(g_testCount, 1, g_testCount);
|
||||
g_testCount++;
|
||||
|
|
|
@ -88,7 +88,7 @@ static UINT32 Testcase(VOID)
|
|||
LOS_EventInit(&g_pevent);
|
||||
|
||||
ret = LOS_TaskCreate(&g_testTaskID01, &task1);
|
||||
ICUNIT_GOTO_EQUAL(ret, LOS_OK, ret, EXIT);
|
||||
ICUNIT_ASSERT_EQUAL(ret, LOS_OK, ret);
|
||||
|
||||
ICUNIT_ASSERT_EQUAL(g_testCount, 1, g_testCount);
|
||||
g_testCount++;
|
||||
|
|
|
@ -85,13 +85,10 @@ static UINT32 Testcase(VOID)
|
|||
LOS_EventInit(&g_pevent);
|
||||
|
||||
ret = LOS_TaskCreate(&g_testTaskID01, &task1);
|
||||
ICUNIT_GOTO_EQUAL(ret, LOS_OK, ret, EXIT);
|
||||
ICUNIT_ASSERT_EQUAL(ret, LOS_OK, ret);
|
||||
|
||||
ICUNIT_ASSERT_EQUAL(g_testCount, 5, g_testCount); // 5, Here, assert that g_testCount is equal to 5.
|
||||
|
||||
return LOS_OK;
|
||||
|
||||
EXIT:
|
||||
LOS_TaskDelete(g_testTaskID01);
|
||||
|
||||
return LOS_OK;
|
||||
|
|
|
@ -129,14 +129,13 @@ static UINT32 Testcase(VOID)
|
|||
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 3, g_testCount, EXIT2); // 3, Here, assert that g_testCount is equal to 3.
|
||||
|
||||
ret = LOS_EventWrite(&g_pevent, 0xF);
|
||||
(VOID)LOS_EventWrite(&g_pevent, 0xF);
|
||||
|
||||
LOS_TaskDelay(1);
|
||||
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 6, g_testCount, EXIT3); // 6, Here, assert that g_testCount is equal to 6.
|
||||
ICUNIT_ASSERT_EQUAL(g_testCount, 6, g_testCount); // 6, Here, assert that g_testCount is equal to 6.
|
||||
|
||||
EXIT3:
|
||||
ret = LOS_EventClear(&g_pevent, 0);
|
||||
(VOID)LOS_EventClear(&g_pevent, 0);
|
||||
ICUNIT_ASSERT_EQUAL(ret, LOS_OK, ret);
|
||||
|
||||
ret = LOS_EventDestroy(&g_pevent);
|
||||
|
|
|
@ -77,10 +77,9 @@ static UINT32 Testcase(VOID)
|
|||
|
||||
LOS_EventClear(&g_pevent, (~(0x11)));
|
||||
|
||||
ret = LOS_TaskResume(g_testTaskID01);
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 4, g_testCount, EXIT1); // 4, Here, assert that g_testCount is equal to 4.
|
||||
(VOID)LOS_TaskResume(g_testTaskID01);
|
||||
ICUNIT_ASSERT_EQUAL(g_testCount, 4, g_testCount); // 4, Here, assert that g_testCount is equal to 4.
|
||||
|
||||
EXIT1:
|
||||
ret = LOS_EventClear(&g_pevent, 0);
|
||||
ICUNIT_ASSERT_EQUAL(ret, LOS_OK, ret);
|
||||
|
||||
|
|
|
@ -52,7 +52,7 @@ static UINT32 TestCase(VOID)
|
|||
ICUNIT_ASSERT_NOT_EQUAL(buf, NULL, buf);
|
||||
buf[7] = '\0'; /* end index 7 */
|
||||
PRINTK("%d\n", __LINE__);
|
||||
ret = strcpy_s(buf, 100, src); /* Check LMS detection information when the strcpy_s dest max set 100 overflows. */
|
||||
(VOID)strcpy_s(buf, 100, src); /* Check LMS detection information when the strcpy_s dest max set 100 overflows. */
|
||||
PRINTK("%d\n", __LINE__);
|
||||
|
||||
ret = LOS_MemFree(g_testLmsPool, buf);
|
||||
|
|
|
@ -59,7 +59,7 @@ static UINT32 Testcase(VOID)
|
|||
task.uwStackSize = LOSCFG_BASE_CORE_TSK_DEFAULT_STACK_SIZE;
|
||||
task.uwResved = 0;
|
||||
|
||||
ret = LOS_TaskCreate(&g_testTaskID01, &task);
|
||||
(VOID)LOS_TaskCreate(&g_testTaskID01, &task);
|
||||
ICUNIT_ASSERT_EQUAL(g_testCount, 1, g_testCount); // 1, Here, assert that g_testCount is equal to 1.
|
||||
|
||||
ret = LOS_MuxDelete(g_mutexTest);
|
||||
|
|
|
@ -68,7 +68,7 @@ static UINT32 Testcase(VOID)
|
|||
task.uwStackSize = LOSCFG_BASE_CORE_TSK_DEFAULT_STACK_SIZE;
|
||||
task.uwResved = 0;
|
||||
|
||||
ret = LOS_TaskCreate(&g_testTaskID01, &task);
|
||||
(VOID)LOS_TaskCreate(&g_testTaskID01, &task);
|
||||
|
||||
ICUNIT_ASSERT_EQUAL(g_testCount, 1, g_testCount); // 1, Here, assert that g_testCount is equal to 1.
|
||||
|
||||
|
|
|
@ -70,7 +70,7 @@ static UINT32 Testcase(VOID)
|
|||
task.uwStackSize = LOSCFG_BASE_CORE_TSK_DEFAULT_STACK_SIZE;
|
||||
task.uwResved = 0;
|
||||
|
||||
ret = LOS_TaskCreate(&g_testTaskID01, &task);
|
||||
(VOID)LOS_TaskCreate(&g_testTaskID01, &task);
|
||||
|
||||
task2.pfnTaskEntry = (TSK_ENTRY_FUNC)TaskF01;
|
||||
task2.usTaskPrio = (TASK_PRIO_TEST - 2); // 2, set new task priority, it is higher than the current task.
|
||||
|
|
|
@ -68,7 +68,7 @@ static UINT32 Testcase(VOID)
|
|||
ICUNIT_GOTO_EQUAL(g_testCount, 2, g_testCount, EXIT); // 2, Here, assert that g_testCount is equal to 2.
|
||||
|
||||
EXIT:
|
||||
ret = LOS_TaskDelete(g_testTaskID01);
|
||||
(VOID)LOS_TaskDelete(g_testTaskID01);
|
||||
|
||||
EXIT2:
|
||||
ret = LOS_SemDelete(g_usSemID);
|
||||
|
|
|
@ -61,7 +61,7 @@ static UINT32 Testcase(VOID)
|
|||
ret = LOS_SwtmrStart(swTmrID);
|
||||
ICUNIT_GOTO_EQUAL(ret, LOS_OK, ret, EXIT);
|
||||
|
||||
ret = LOS_TaskDelay(10); // 10, set delay time.
|
||||
(VOID)LOS_TaskDelay(10); // 10, set delay time.
|
||||
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 1, g_testCount, EXIT);
|
||||
|
||||
|
|
|
@ -88,7 +88,7 @@ static UINT32 Testcase(VOID)
|
|||
ret = LOS_SwtmrStart(g_swTmrID2);
|
||||
ICUNIT_GOTO_EQUAL(ret, LOS_OK, ret, EXIT);
|
||||
|
||||
ret = LOS_TaskDelay(10); // 10, set delay time.
|
||||
(VOID)LOS_TaskDelay(10); // 10, set delay time.
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 1, g_testCount, EXIT);
|
||||
|
||||
return LOS_OK;
|
||||
|
|
|
@ -49,8 +49,6 @@ static UINT32 Testcase(VOID)
|
|||
{
|
||||
UINT32 ret;
|
||||
g_testCount1 = 0;
|
||||
UINT64 tickRecord;
|
||||
UINT64 tickUpdate;
|
||||
UINT64 deltaTicks;
|
||||
|
||||
// 4, Timeout interval of a periodic software timer.
|
||||
|
|
|
@ -50,7 +50,6 @@ static UINT32 TestCase(VOID)
|
|||
|
||||
task1.pfnTaskEntry = (TSK_ENTRY_FUNC)TaskF01;
|
||||
task1.uwStackSize = LOSCFG_BASE_CORE_TSK_MIN_STACK_SIZE;
|
||||
task1.usTaskPrio = TASK_PRIO_TEST + 1;
|
||||
g_testCount = 0;
|
||||
|
||||
LOS_TaskLock();
|
||||
|
@ -64,7 +63,6 @@ static UINT32 TestCase(VOID)
|
|||
ICUNIT_GOTO_EQUAL(ret, LOS_OK, ret, EXIT);
|
||||
}
|
||||
|
||||
task1.usTaskPrio = index % OS_TASK_PRIORITY_LOWEST;
|
||||
task1.pcName = "TskA";
|
||||
task1.uwResved = LOS_TASK_STATUS_DETACHED;
|
||||
ret = LOS_TaskCreate(&testTaskID[index], &task1);
|
||||
|
|
|
@ -46,10 +46,8 @@ static VOID TaskF01(UINT32 arg)
|
|||
static UINT32 TestCase(VOID)
|
||||
{
|
||||
UINT32 freeMem;
|
||||
UINT32 freeMem1;
|
||||
UINT32 freeMem2;
|
||||
UINT32 freeMem3;
|
||||
UINT32 freeMem4;
|
||||
UINT32 ret;
|
||||
|
||||
TSK_INIT_PARAM_S task1 = { 0 };
|
||||
|
@ -66,7 +64,7 @@ static UINT32 TestCase(VOID)
|
|||
|
||||
ICUNIT_ASSERT_EQUAL(g_testCount, 1, g_testCount);
|
||||
|
||||
freeMem1 = GetfreeMemSize(m_aucSysMem0);
|
||||
(VOID)GetfreeMemSize(m_aucSysMem0);
|
||||
|
||||
LOS_TaskDelay(10); // 10, task delay times.
|
||||
|
||||
|
|
|
@ -55,7 +55,6 @@ static VOID TaskF01(VOID)
|
|||
static UINT32 TestCase(VOID)
|
||||
{
|
||||
UINT32 freeMem;
|
||||
UINT32 freeMem1;
|
||||
UINT32 freeMem2;
|
||||
UINT32 ret;
|
||||
TSK_INIT_PARAM_S task1 = { 0 };
|
||||
|
|
|
@ -59,7 +59,6 @@ EXIT:
|
|||
|
||||
static VOID *PthreadF02(void *t)
|
||||
{
|
||||
int i;
|
||||
int rc;
|
||||
|
||||
ICUNIT_GOTO_EQUAL(g_testCount, 1, g_testCount, EXIT);
|
||||
|
|
|
@ -33,8 +33,6 @@
|
|||
static UINT32 Testcase(VOID)
|
||||
{
|
||||
pthread_condattr_t condattr;
|
||||
pthread_cond_t cond1;
|
||||
pthread_cond_t cond2;
|
||||
int pshared;
|
||||
int rc;
|
||||
|
||||
|
|
|
@ -743,7 +743,6 @@ LITE_TEST_CASE(PthreadFuncTestSuite, TestPthread011, Function | MediumTest | Lev
|
|||
pthread_t thread;
|
||||
struct sched_param schedParam = { 0 };
|
||||
UINT32 ret;
|
||||
pthread_once_t onceControl = 0;
|
||||
g_testCount = 0;
|
||||
ret = pthread_attr_init(&attr);
|
||||
ICUNIT_ASSERT_EQUAL(ret, 0, ret);
|
||||
|
@ -804,7 +803,6 @@ LITE_TEST_CASE(PthreadFuncTestSuite, TestPthread012, Function | MediumTest | Lev
|
|||
pthread_t thread;
|
||||
struct sched_param schedParam = { 0 };
|
||||
UINT32 ret;
|
||||
pthread_once_t onceControl = 0;
|
||||
|
||||
g_testCount = 0;
|
||||
g_pthreadSem = 0;
|
||||
|
|
|
@ -45,7 +45,6 @@ extern int g_iteration;
|
|||
|
||||
static uint32_t RegexFuzz(void)
|
||||
{
|
||||
int fd;
|
||||
int ret;
|
||||
regex_t preg;
|
||||
regmatch_t pmatch[1];
|
||||
|
@ -56,7 +55,6 @@ static uint32_t RegexFuzz(void)
|
|||
const int maxStrLen = 5;
|
||||
const int maxNumRange = 6;
|
||||
const int maxNum1Range = 3;
|
||||
int spid;
|
||||
int num;
|
||||
int num1;
|
||||
char *string1 = NULL;
|
||||
|
|
|
@ -52,7 +52,7 @@ void SemTimedWaitFuzzTest(void)
|
|||
const int elemNsecIndex = 5;
|
||||
struct timespec absTimeout;
|
||||
sem_t sem;
|
||||
int pshared, value, getvalue;
|
||||
int pshared, value;
|
||||
|
||||
printf("Fuzz test in line [%d] sem_timedwait start\n", __LINE__);
|
||||
|
||||
|
|
|
@ -71,7 +71,6 @@ static void *SampleUdpServer()
|
|||
struct sockaddr_in clnAddr = { 0 };
|
||||
socklen_t clnAddrLen = sizeof(clnAddr);
|
||||
char buf[BUF_SIZE] = { 0 };
|
||||
int flag;
|
||||
struct msghdr msg = { 0 };
|
||||
struct iovec iov[2] = { };
|
||||
|
||||
|
@ -134,7 +133,6 @@ static void *SampleUdpClient()
|
|||
msg.msg_iov = iov;
|
||||
msg.msg_iovlen = 1;
|
||||
iov[0].iov_base = buf;
|
||||
iov[0].iov_len = sizeof(buf);
|
||||
(void)recvmsg(fd, &msg, 0x40);
|
||||
printf("c6\r\n");
|
||||
|
||||
|
@ -150,7 +148,6 @@ static UINT32 UdpFun(VOID)
|
|||
UINT8 num2;
|
||||
UINT8 num3;
|
||||
UINT8 num4;
|
||||
UINT8 num5;
|
||||
|
||||
INIT_FuzzEnvironment();
|
||||
printf("UDPFun starts\n");
|
||||
|
@ -160,7 +157,6 @@ static UINT32 UdpFun(VOID)
|
|||
num2 = *(UINT8 *)DT_SetGetU8(&g_element[NUM_1_INDEX], 1);
|
||||
num3 = *(UINT8 *)DT_SetGetU8(&g_element[NUM_2_INDEX], 1);
|
||||
num4 = *(UINT8 *)DT_SetGetU8(&g_element[NUM_3_INDEX], 1);
|
||||
num5 = *(UINT8 *)DT_SetGetU8(&g_element[NUM_4_INDEX], 1);
|
||||
|
||||
(void)snprintf_s(g_udpIp, sizeof(g_udpIp), sizeof(g_udpIp) - 1, "%d.%d.%d.%d", num1, num2, num3, num4);
|
||||
g_udpPort = *(UINT16 *)DT_SetGetU16(&g_element[NUM_5_INDEX], 0);
|
||||
|
@ -244,7 +240,6 @@ static void *SampleTcpClient()
|
|||
char buf[BUF_SIZE + 1] = { 0 };
|
||||
int sfd = -1;
|
||||
struct sockaddr_in srvAddr = { 0 };
|
||||
struct sockaddr_in clnAddr = { 0 };
|
||||
int ret;
|
||||
|
||||
struct sockaddr addr;
|
||||
|
|
|
@ -48,7 +48,7 @@ extern int g_iteration;
|
|||
|
||||
void StrtoullFuzzTest(void)
|
||||
{
|
||||
int base = DEFAULT_BASE_VALUE;
|
||||
int base;
|
||||
char *str = NULL;
|
||||
char *endPtr = NULL;
|
||||
|
||||
|
|
|
@ -241,7 +241,6 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFopenFclose004, Function | MediumTest
|
|||
*/
|
||||
LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFopenFclose005, Function | MediumTest | Level1)
|
||||
{
|
||||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "c");
|
||||
TEST_ASSERT_NULL(fp);
|
||||
|
@ -350,7 +349,6 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFopenFclose010, Function | MediumTest
|
|||
*/
|
||||
LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFopenFclose011, Function | MediumTest | Level1)
|
||||
{
|
||||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, NULL);
|
||||
|
@ -660,7 +658,7 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFtellFseek008, Function | MediumTest
|
|||
*/
|
||||
LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFtellFseek009, Function | MediumTest | Level1)
|
||||
{
|
||||
int ret = 0;
|
||||
int ret;
|
||||
FILE *fp = NULL;
|
||||
long off = 0;
|
||||
|
||||
|
@ -884,7 +882,6 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFputs001, Function | MediumTest | Lev
|
|||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
char str[TEST_BUF_SIZE] = {0};
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "w");
|
||||
TEST_ASSERT_NOT_NULL(fp);
|
||||
|
@ -907,7 +904,6 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFputs002, Function | MediumTest | Lev
|
|||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
char str[TEST_BUF_SIZE] = {0};
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "a");
|
||||
TEST_ASSERT_NOT_NULL(fp);
|
||||
|
@ -930,7 +926,6 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFputs003, Function | MediumTest | Lev
|
|||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
char str[TEST_BUF_SIZE] = {0};
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "w+");
|
||||
TEST_ASSERT_NOT_NULL(fp);
|
||||
|
@ -983,7 +978,6 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFputs005, Function | MediumTest | Lev
|
|||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
char str[TEST_BUF_SIZE] = {0};
|
||||
int i;
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "w+");
|
||||
|
@ -1011,12 +1005,8 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFreadFwrite001, Function | MediumTest
|
|||
{
|
||||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
long off = 0;
|
||||
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
const char chr2[TEST_BUF_SIZE] = "world";
|
||||
|
||||
char str[TEST_BUF_SIZE] = {0};
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "w");
|
||||
TEST_ASSERT_NOT_NULL(fp);
|
||||
|
@ -1038,12 +1028,6 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFreadFwrite002, Function | MediumTest
|
|||
{
|
||||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
long off = 0;
|
||||
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
const char chr2[TEST_BUF_SIZE] = "world";
|
||||
|
||||
char str[TEST_BUF_SIZE] = {0};
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "w");
|
||||
TEST_ASSERT_NOT_NULL(fp);
|
||||
|
@ -1065,12 +1049,8 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFreadFwrite003, Function | MediumTest
|
|||
{
|
||||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
long off = 0;
|
||||
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
const char chr2[TEST_BUF_SIZE] = "world";
|
||||
|
||||
char str[TEST_BUF_SIZE] = {0};
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "r");
|
||||
TEST_ASSERT_NOT_NULL(fp);
|
||||
|
@ -1092,12 +1072,6 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFreadFwrite004, Function | MediumTest
|
|||
{
|
||||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
long off = 0;
|
||||
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
const char chr2[TEST_BUF_SIZE] = "world";
|
||||
|
||||
char str[TEST_BUF_SIZE] = {0};
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "r");
|
||||
TEST_ASSERT_NOT_NULL(fp);
|
||||
|
@ -1119,12 +1093,8 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFreadFwrite005, Function | MediumTest
|
|||
{
|
||||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
long off = 0;
|
||||
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
const char chr2[TEST_BUF_SIZE] = "world";
|
||||
|
||||
char str[TEST_BUF_SIZE] = {0};
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "a");
|
||||
TEST_ASSERT_NOT_NULL(fp);
|
||||
|
@ -1146,7 +1116,6 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFreadFwrite006, Function | MediumTest
|
|||
{
|
||||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
long off = 0;
|
||||
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
const char chr2[TEST_BUF_SIZE] = "world";
|
||||
|
@ -1189,7 +1158,6 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsFreadFwrite007, Function | MediumTest
|
|||
{
|
||||
int ret = 0;
|
||||
FILE *fp = NULL;
|
||||
long off = 0;
|
||||
|
||||
const char chr1[TEST_BUF_SIZE] = "hello";
|
||||
const char chr2[TEST_BUF_SIZE] = "world";
|
||||
|
@ -1330,7 +1298,7 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsReaddir002, Function | MediumTest | L
|
|||
struct dirent *dResult;
|
||||
off_t tellDir0;
|
||||
off_t tellDir1;
|
||||
int ret = 0;
|
||||
int ret;
|
||||
|
||||
ret = mkdir(DIRA, 0777);
|
||||
dirp = opendir((DIRA));
|
||||
|
@ -1359,7 +1327,7 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsReaddir002, Function | MediumTest | L
|
|||
LITE_TEST_CASE(PosixFsFuncTestSuite, testFsRemove001, Function | MediumTest | Level1)
|
||||
{
|
||||
FILE *fp = NULL;
|
||||
int ret = 0;
|
||||
int ret;
|
||||
|
||||
fp = fopen(TEST_FILE_PTAH_RIGHT, "w");
|
||||
fclose(fp);
|
||||
|
@ -1375,7 +1343,7 @@ LITE_TEST_CASE(PosixFsFuncTestSuite, testFsRemove001, Function | MediumTest | Le
|
|||
*/
|
||||
LITE_TEST_CASE(PosixFsFuncTestSuite, testFsRemove002, Function | MediumTest | Level1)
|
||||
{
|
||||
int ret = 0;
|
||||
int ret;
|
||||
|
||||
ret = mkdir(DIRA, 0777);
|
||||
TEST_ASSERT_EQUAL_INT(ret, 0);
|
||||
|
|
|
@ -765,7 +765,6 @@ LITE_TEST_CASE(PthreadFuncTestSuite, testPthread011, Function | MediumTest | Lev
|
|||
pthread_t thread;
|
||||
struct sched_param schedParam = { 0 };
|
||||
UINT32 ret;
|
||||
pthread_once_t onceControl = 0;
|
||||
g_testCount = 0;
|
||||
ret = pthread_attr_init(&attr);
|
||||
ICUNIT_ASSERT_EQUAL(ret, 0, ret);
|
||||
|
@ -825,7 +824,6 @@ LITE_TEST_CASE(PthreadFuncTestSuite, testPthread012, Function | MediumTest | Lev
|
|||
pthread_t thread;
|
||||
struct sched_param schedParam = { 0 };
|
||||
UINT32 ret;
|
||||
pthread_once_t onceControl = 0;
|
||||
|
||||
g_testCount = 0;
|
||||
g_pthreadSem = 0;
|
||||
|
|
|
@ -105,7 +105,6 @@ LITE_TEST_CASE(PosixSemaphoreFuncTestSuite, testIpcSem_Timedwait001, Function |
|
|||
struct timespec ts = { 0 };
|
||||
struct timespec tsNow = { 0 };
|
||||
sem_t sem;
|
||||
int semValue = 0;
|
||||
|
||||
TEST_ASSERT_EQUAL_INT(0, sem_init((sem_t *)&sem, 0, 0));
|
||||
|
||||
|
@ -138,7 +137,6 @@ LITE_TEST_CASE(PosixSemaphoreFuncTestSuite, testIpcSem_Timedwait002, Function |
|
|||
struct timespec tsNow = { 0 };
|
||||
struct timespec tsBegin = { 0 };
|
||||
sem_t sem;
|
||||
int semValue = 0;
|
||||
|
||||
TEST_ASSERT_EQUAL_INT(0, sem_init((sem_t *)&sem, 0, 1));
|
||||
|
||||
|
|
Loading…
Reference in New Issue