Home
last modified time | relevance | path

Searched refs:retValue (Results 1 – 25 of 42) sorted by relevance

12

/kernel/liteos_a/testsuites/unittest/extended/signal/full/
Dsignal_test_020.cpp47 int status, retValue; in TestSigSuspend() local
55 retValue = sigemptyset(&act.sa_mask); in TestSigSuspend()
56 if (retValue != 0) { in TestSigSuspend()
57 exit(retValue); in TestSigSuspend()
65 retValue = sigemptyset(&newset); in TestSigSuspend()
66 if (retValue != 0) { in TestSigSuspend()
67 exit(retValue); in TestSigSuspend()
69 retValue = sigaddset(&newset, SIGALRM); in TestSigSuspend()
70 if (retValue != 0) { in TestSigSuspend()
71 exit(retValue); in TestSigSuspend()
[all …]
Dsignal_test_017.cpp42 int retValue; in ThreadSetFunc2() local
46 retValue = sigemptyset(&set); in ThreadSetFunc2()
47 ICUNIT_ASSERT_EQUAL_NULL(retValue, 0, retValue); in ThreadSetFunc2()
48 retValue = sigaddset(&set, SIGALRM); in ThreadSetFunc2()
49 ICUNIT_ASSERT_EQUAL_NULL(retValue, 0, retValue); in ThreadSetFunc2()
50 retValue = sigaddset(&set, SIGUSR1); in ThreadSetFunc2()
51 ICUNIT_ASSERT_EQUAL_NULL(retValue, 0, retValue); in ThreadSetFunc2()
53 retValue = sigwait(&set, &sig); in ThreadSetFunc2()
54 ICUNIT_ASSERT_EQUAL_NULL(retValue, 0, retValue); in ThreadSetFunc2()
61 int retValue; in ThreadSetDfl() local
[all …]
Dsignal_test_016.cpp42 int retValue; in ThreadSetFunc2() local
46 retValue = sigemptyset(&set); in ThreadSetFunc2()
47 ICUNIT_ASSERT_EQUAL_NULL(retValue, 0, retValue); in ThreadSetFunc2()
48 retValue = sigaddset(&set, SIGALRM); in ThreadSetFunc2()
49 ICUNIT_ASSERT_EQUAL_NULL(retValue, 0, retValue); in ThreadSetFunc2()
50 retValue = sigaddset(&set, SIGUSR1); in ThreadSetFunc2()
51 ICUNIT_ASSERT_EQUAL_NULL(retValue, 0, retValue); in ThreadSetFunc2()
53 retValue = sigwait(&set, &sig); in ThreadSetFunc2()
54 ICUNIT_ASSERT_EQUAL_NULL(retValue, 0, retValue); in ThreadSetFunc2()
60 int retValue; in ThreadSetDfl() local
[all …]
Dsignal_test_028.cpp53 int retValue, status; in TestSigset() local
59 retValue = sigemptyset(&sigset); in TestSigset()
60 if (retValue != 0) { in TestSigset()
61 exit(retValue); in TestSigset()
68 retValue = sigisemptyset(&sigset); in TestSigset()
69 if (retValue != 1) { in TestSigset()
70 exit(retValue); in TestSigset()
72 if (retValue == 1) { in TestSigset()
80 retValue = sigaddset(&sigset, SIGINT); in TestSigset()
81 if (retValue != 0) { in TestSigset()
[all …]
Dsignal_test_010.cpp48 int sig, fpid, retValue, status; in TestSigWait() local
56 retValue = sigemptyset(&set); in TestSigWait()
57 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigWait()
58 retValue = sigaddset(&set, SIGALRM); in TestSigWait()
59 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigWait()
60 retValue = sigaddset(&set, SIGUSR1); in TestSigWait()
61 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigWait()
68 retValue = sigwait(&set, &sig); in TestSigWait()
69 if (retValue != 0) { in TestSigWait()
70 exit(retValue); in TestSigWait()
[all …]
Dsignal_test_025.cpp43 int retValue, status; in TestBlock() local
58 retValue = sighold(sig); in TestBlock()
59 if (retValue != 0) { in TestBlock()
60 exit(retValue); in TestBlock()
70 retValue = sigrelse(sig); in TestBlock()
71 if (retValue != 0) { in TestBlock()
72 exit(retValue); in TestBlock()
84 retValue = sigpause(sig); in TestBlock()
85 if (retValue != -1) { in TestBlock()
86 exit(retValue); in TestBlock()
[all …]
Dsignal_test_018.cpp43 int sig, fpid, retValue, status; in TestSigTimeWaitKillProcess() local
55 retValue = sigemptyset(&set); in TestSigTimeWaitKillProcess()
56 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigTimeWaitKillProcess()
57 retValue = sigaddset(&set, SIGALRM); in TestSigTimeWaitKillProcess()
58 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigTimeWaitKillProcess()
59 retValue = sigaddset(&set, SIGUSR1); in TestSigTimeWaitKillProcess()
60 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigTimeWaitKillProcess()
67 retValue = sigtimedwait(&set, &si, &ts); in TestSigTimeWaitKillProcess()
68 if (retValue != SIGUSR1) { in TestSigTimeWaitKillProcess()
69 exit(retValue); in TestSigTimeWaitKillProcess()
[all …]
Dsignal_test_011.cpp42 int sig, fpid, retValue, status; in TestSigTimeWait() local
53 retValue = sigemptyset(&set); in TestSigTimeWait()
54 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigTimeWait()
55 retValue = sigaddset(&set, SIGALRM); in TestSigTimeWait()
56 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigTimeWait()
57 retValue = sigaddset(&set, SIGUSR1); in TestSigTimeWait()
58 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigTimeWait()
65 retValue = sigtimedwait(&set, &si, &ts); in TestSigTimeWait()
66 if (retValue == -1 && errno != EAGAIN) { in TestSigTimeWait()
78 retValue = kill(fpid, SIGUSR1); in TestSigTimeWait()
[all …]
Dsignal_test_019.cpp43 int sig, fpid, retValue, status; in TestSigTimeWaitDirectKillChild() local
55 retValue = sigemptyset(&set); in TestSigTimeWaitDirectKillChild()
56 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigTimeWaitDirectKillChild()
57 retValue = sigaddset(&set, SIGALRM); in TestSigTimeWaitDirectKillChild()
58 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigTimeWaitDirectKillChild()
59 retValue = sigaddset(&set, SIGUSR1); in TestSigTimeWaitDirectKillChild()
60 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigTimeWaitDirectKillChild()
67 retValue = sigtimedwait(&set, &si, &ts); in TestSigTimeWaitDirectKillChild()
68 if (retValue != 0) { in TestSigTimeWaitDirectKillChild()
69 exit(retValue); in TestSigTimeWaitDirectKillChild()
[all …]
Dsignal_test_001.cpp47 int retValue; in TestRaiseMuliti() local
54 retValue = raise(sig); in TestRaiseMuliti()
55 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestRaiseMuliti()
73 int retValue; in TestCase() local
75 retValue = sigprocmask(1, NULL, NULL); in TestCase()
76 if (retValue != 0) { in TestCase()
84 if (retValue != -1 || errno != ESRCH) { in TestCase()
89 if (retValue != -1 || errno != ESRCH) { in TestCase()
94 if (retValue != -1 || errno != EINVAL) { in TestCase()
99 if (retValue != -1 || errno != EINVAL) { in TestCase()
[all …]
Dpipe_test_006.cpp43 int retValue = -1; in PipeUnlinkTest() local
53 retValue = pipe(pipefd[i]); in PipeUnlinkTest()
54 ICUNIT_ASSERT_EQUAL_EXIT(retValue, 0, __LINE__); in PipeUnlinkTest()
56 retValue = pipe(tmpFd); in PipeUnlinkTest()
57 ICUNIT_ASSERT_EQUAL_EXIT(retValue, -1, __LINE__); in PipeUnlinkTest()
60 retValue = unlink(devName); in PipeUnlinkTest()
61 ICUNIT_ASSERT_EQUAL_EXIT(retValue, -1, __LINE__); in PipeUnlinkTest()
62 retValue = close(pipefd[i][0]); in PipeUnlinkTest()
63 ICUNIT_ASSERT_EQUAL_EXIT(retValue, 0, __LINE__); in PipeUnlinkTest()
64 retValue = unlink(devName); in PipeUnlinkTest()
[all …]
Dsignal_test_012.cpp41 int retValue; in TestSigTimeWaitMultiPthread() local
50 retValue = sigemptyset(&waitSet); in TestSigTimeWaitMultiPthread()
51 if (retValue != 0) { in TestSigTimeWaitMultiPthread()
52 exit(retValue); in TestSigTimeWaitMultiPthread()
54 retValue = sigaddset(&waitSet, SIGALRM); in TestSigTimeWaitMultiPthread()
55 if (retValue != 0) { in TestSigTimeWaitMultiPthread()
56 exit(retValue); in TestSigTimeWaitMultiPthread()
61 retValue = sigwait(&waitSet, &receivedSignal); in TestSigTimeWaitMultiPthread()
62 if (retValue != 0) { in TestSigTimeWaitMultiPthread()
63 exit(retValue); in TestSigTimeWaitMultiPthread()
[all …]
Dsignal_test_004.cpp48 int status, retValue; in TestRaiseWake() local
60 retValue = kill(fatherPid, SIGTERM); in TestRaiseWake()
61 if (retValue != 0) { in TestRaiseWake()
62 exit(retValue); in TestRaiseWake()
82 retValue = waitpid(fpid, &status, 0); in TestRaiseWake()
83 ICUNIT_ASSERT_EQUAL(retValue, fpid, retValue); in TestRaiseWake()
91 int retValue, status; in TestCase() local
95 retValue = TestRaiseWake(); in TestCase()
96 if (retValue != SIG_TEST_COUNT) { in TestCase()
97 exit(retValue); in TestCase()
[all …]
Dsignal_test_015.cpp43 int retValue; in TestPauseNormal() local
67 retValue = kill(fpid, SIGUSR1); in TestPauseNormal()
71 retValue = kill(fpid, SIGPWR); in TestPauseNormal()
72 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestPauseNormal()
73 retValue = waitpid(fpid, &status, 0); in TestPauseNormal()
74 ICUNIT_ASSERT_EQUAL(retValue, fpid, retValue); in TestPauseNormal()
92 retValue = kill(fpid, SIGKILL); in TestPauseNormal()
93 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestPauseNormal()
94 retValue = waitpid(fpid, &status, 0); in TestPauseNormal()
95 ICUNIT_ASSERT_EQUAL(retValue, fpid, retValue); in TestPauseNormal()
Dsignal_test_006.cpp42 int retValue, fpid, status; in TestSigDefActionChild() local
47 retValue = raise(SIGALRM); in TestSigDefActionChild()
48 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigDefActionChild()
53 retValue = raise(SIGALRM); in TestSigDefActionChild()
54 if (retValue != 0) { in TestSigDefActionChild()
55 exit(retValue); in TestSigDefActionChild()
59 retValue = waitpid(fpid, &status, 0); in TestSigDefActionChild()
60 ICUNIT_ASSERT_EQUAL(retValue, fpid, retValue); in TestSigDefActionChild()
Dsignal_test_007.cpp47 int fpid, fpids, status, retValue; in TestSigKillResp() local
60 retValue = kill(fpids, SIGKILL); in TestSigKillResp()
61 if (retValue != 0) { in TestSigKillResp()
62 exit(retValue); in TestSigKillResp()
64 retValue = waitpid(fpids, NULL, 0); in TestSigKillResp()
65 if (retValue != fpids) { in TestSigKillResp()
66 exit(retValue); in TestSigKillResp()
70 retValue = waitpid(fpid, &status, 0); in TestSigKillResp()
71 ICUNIT_ASSERT_EQUAL(retValue, fpid, retValue); in TestSigKillResp()
Dsignal_test_008.cpp46 int fpid, fpids, status, retValue; in TestSigKillWaitFromSigChild() local
62 retValue = kill(fpids, SIGKILL); in TestSigKillWaitFromSigChild()
63 if (retValue != 0) { in TestSigKillWaitFromSigChild()
64 exit(retValue); in TestSigKillWaitFromSigChild()
66 retValue = waitpid(fpids, &status, 0); in TestSigKillWaitFromSigChild()
67 if (retValue != fpids) { in TestSigKillWaitFromSigChild()
68 exit(retValue); in TestSigKillWaitFromSigChild()
72 retValue = waitpid(fpid, &status, 0); in TestSigKillWaitFromSigChild()
73 ICUNIT_ASSERT_EQUAL(retValue, fpid, retValue); in TestSigKillWaitFromSigChild()
/kernel/liteos_a/testsuites/unittest/extended/signal/smoke/
Dsignal_test_009.cpp55 int retValue; in TestSigSet() local
60 retValue = sigandset(&set, &left, &right); in TestSigSet()
62 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigSet()
67 retValue = sigandset(&set, &left, &right); in TestSigSet()
69 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigSet()
74 retValue = sigandset(&set, &left, &right); in TestSigSet()
76 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigSet()
78 retValue = sigorset(&set, &left, &right); in TestSigSet()
80 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestSigSet()
82 retValue = sigdelset(&set, 1); in TestSigSet()
[all …]
Dsignal_test_024.cpp48 int retValue, status; in TestSigaction() local
53 retValue = sigemptyset(&curAction.sa_mask); in TestSigaction()
54 if (retValue != 0) { in TestSigaction()
55 exit(retValue); in TestSigaction()
60 retValue = sigaction(SIGINT, &curAction, NULL); in TestSigaction()
61 if (retValue != 0) { in TestSigaction()
62 exit(retValue); in TestSigaction()
64 retValue = raise(SIGINT); in TestSigaction()
65 if (retValue != 0) { in TestSigaction()
66 exit(retValue); in TestSigaction()
[all …]
Dsignal_test_022.cpp43 int retValue, status; in TestRaise() local
52 retValue = raise(sig); in TestRaise()
53 if (retValue != 0) { in TestRaise()
54 exit(retValue); in TestRaise()
63 retValue = raise(sig); in TestRaise()
64 if (retValue != 0) { in TestRaise()
65 exit(retValue); in TestRaise()
73 retValue = raise(sig); in TestRaise()
74 if (retValue != 0) { in TestRaise()
75 exit(retValue); in TestRaise()
[all …]
DIt_ipc_pipe_004.cpp38 int retValue = pipe2(pipefd, O_CLOEXEC); in TestCase() local
39 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestCase()
55 retValue = sprintf_s(a, sizeof(a), "%d", i); in TestCase()
56 ICUNIT_ASSERT_NOT_EQUAL(retValue, 0, retValue); in TestCase()
57 retValue = strcat_s(sentence1, sizeof(sentence1), a); in TestCase()
58 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestCase()
63 retValue = memset_s(readbuffer, sizeof(readbuffer), 0, sizeof(readbuffer)); in TestCase()
64 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestCase()
65 retValue = read(*readFd, readbuffer, sizeof(readbuffer)); in TestCase()
66 … ICUNIT_ASSERT_EQUAL(retValue, 13, retValue); // 13, assert that function Result is equal to this. in TestCase()
Dsignal_test_002.cpp46 int retValue; in TestRaiseIgnore() local
53 retValue = raise(sig); in TestRaiseIgnore()
54 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestRaiseIgnore()
61 retValue = raise(sig); in TestRaiseIgnore()
62 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestRaiseIgnore()
66 retValue = raise(sig); in TestRaiseIgnore()
67 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue); in TestRaiseIgnore()
Dsignal_test_021.cpp53 int retValue, status; in TestSignal() local
64 retValue = raise(sigI); in TestSignal()
65 if (retValue != 0) { in TestSignal()
66 exit(retValue); in TestSignal()
74 retValue = raise(sigQ); in TestSignal()
75 if (retValue != 0) { in TestSignal()
76 exit(retValue); in TestSignal()
81 retValue = waitpid(fpid, &status, 0); in TestSignal()
82 ICUNIT_ASSERT_EQUAL(retValue, fpid, retValue); in TestSignal()
/kernel/liteos_m/testsuites/unittest/posix/src/string/
Dmemory_func_test.c75 void *retValue = NULL; variable
78 retValue = memcpy(dest, source, sizeof(source) / sizeof(source[0]));
80 ICUNIT_ASSERT_NOT_EQUAL(retValue, NULL, 0);
82 retValue = memcpy(source, dest, sizeof(source) / sizeof(source[0]));
83 ICUNIT_ASSERT_NOT_EQUAL(retValue, NULL, 0);
115 void *retValue = NULL; variable
120 retValue = memcpy(dest, source, sizeof(source) / sizeof(source[0]));
121 ICUNIT_ASSERT_NOT_EQUAL(retValue, NULL, 0);
123 retValue = memcpy(source, dest, sizeof(source) / sizeof(source[0]));
124 ICUNIT_ASSERT_NOT_EQUAL(retValue, NULL, 0);
[all …]
Dstring_func_test_03.c76 int retValue = 0; variable
80 retValue = strcmp(source, dest);
81 ICUNIT_ASSERT_EQUAL(retValue, 0, retValue);
100 int retValue = 0; variable
104 retValue = strcmp(source, dest);
105 ICUNIT_ASSERT_WITHIN_EQUAL(retValue, 1, retValue, 0);
117 int retValue = 0; variable
121 retValue = strcmp(source, dest);
122 ICUNIT_ASSERT_WITHIN_EQUAL(retValue, retValue, -1, 0);
180 int retValue = 0; variable
[all …]

12