Changeset 7214 in vbox for trunk/src/VBox/Runtime
- Timestamp:
- Feb 29, 2008 1:45:37 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/testcase/tstNoCrt-1.cpp
r7210 r7214 147 147 } while (0) 148 148 void *pv; 149 150 #define CHECK_DIFF(op) \ 151 do \ 152 { \ 153 if (!(iDiff op 0)) \ 154 { \ 155 RTPrintf("tstNoCrt-1(%d): iDiff=%d expected: %s 0\n", __LINE__, iDiff, #op); \ 156 g_cErrors++; \ 157 } \ 158 } while (0) 159 int iDiff; 160 161 static char s_szTest1[] = "0123456789abcdef"; 162 static char s_szTest2[] = "0123456789abcdef"; 163 static char s_szTest3[] = "fedcba9876543210"; 149 164 150 165 /* … … 370 385 * memchr & strchr. 371 386 */ 372 static char s_szTest1[] = "0123456789abcdef";373 374 387 RTPrintf("tstNoCrt-1: memchr\n"); 375 388 pv = RT_NOCRT(memchr)(&s_szTest1[0x00], 'f', sizeof(s_szTest1)); CHECK_PV(&s_szTest1[0xf]); … … 396 409 } 397 410 398 #define CHECK_DIFF(op) \399 do \400 { \401 if (!(iDiff op 0)) \402 { \403 RTPrintf("tstNoCrt-1(%d): iDiff=%d expected: %s 0\n", __LINE__, iDiff, #op); \404 g_cErrors++; \405 } \406 } while (0)407 int iDiff;408 409 411 /* 410 412 * Some simple memcmp/strcmp checks. 411 413 */ 412 static char s_szTest2[] = "0123456789abcdef";413 static char s_szTest3[] = "fedcba9876543210";414 415 414 RTPrintf("tstNoCrt-1: memcmp\n"); 416 415 iDiff = RT_NOCRT(memcmp)(s_szTest1, s_szTest1, sizeof(s_szTest1)); CHECK_DIFF( == );
Note:
See TracChangeset
for help on using the changeset viewer.