diff options
author | Matt Joyce <matthew.joyce@embedded-brains.de> | 2022-02-15 12:26:12 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2022-02-16 08:25:42 +0100 |
commit | d24da94f620af3b8446a8305056bf690339bbeac (patch) | |
tree | e491aa0c651315ed1bd90c7b5b82df0a464199a8 /testsuites | |
parent | bsp/atsam: Improve UART / USART tx performance (diff) | |
download | rtems-d24da94f620af3b8446a8305056bf690339bbeac.tar.bz2 |
newlib01: Edit asserts to check initialization
Edit assert statements in worker thread to check initialization against the
__cleanup member of struct _reent instead of __sdidinit. This will allow the
removal of sdidinit in a follow up Newlib patch.
Diffstat (limited to 'testsuites')
-rw-r--r-- | testsuites/libtests/newlib01/init.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/testsuites/libtests/newlib01/init.c b/testsuites/libtests/newlib01/init.c index 383abf41f6..c6aeddefdf 100644 --- a/testsuites/libtests/newlib01/init.c +++ b/testsuites/libtests/newlib01/init.c @@ -70,7 +70,7 @@ static void worker_task(rtems_task_argument arg) char buf[1] = { 'x' }; size_t n; - rtems_test_assert(reent->__sdidinit == 0); + rtems_test_assert(reent->__cleanup == NULL); output = stdout = fopen(&file_path[0], "r+"); rtems_test_assert(stdout != NULL); @@ -78,9 +78,9 @@ static void worker_task(rtems_task_argument arg) /* * Check newlib's __sinit does not touch our assigned file pointer. */ - rtems_test_assert(reent->__sdidinit == 0); + rtems_test_assert(reent->__cleanup == NULL); rtems_test_assert(fflush(stdout) == 0); - rtems_test_assert(reent->__sdidinit != 0); + rtems_test_assert(reent->__cleanup != NULL); rtems_test_assert(stdout == output); n = fwrite(&buf[0], sizeof(buf), 1, stdout); |