[rtems commit] psxreaddir: Adjust test due to opendir() changes
Sebastian Huber
sebh at rtems.org
Mon Oct 22 06:16:36 UTC 2018
Module: rtems
Branch: master
Commit: 92e0eedc0aed2ce024209e1e2345116122a155ed
Changeset: http://git.rtems.org/rtems/commit/?id=92e0eedc0aed2ce024209e1e2345116122a155ed
Author: Sebastian Huber <sebastian.huber at embedded-brains.de>
Date: Mon Oct 22 07:58:44 2018 +0200
psxreaddir: Adjust test due to opendir() changes
Update #3545.
---
testsuites/psxtests/psxreaddir/test.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/testsuites/psxtests/psxreaddir/test.c b/testsuites/psxtests/psxreaddir/test.c
index c793931..e32bac4 100644
--- a/testsuites/psxtests/psxreaddir/test.c
+++ b/testsuites/psxtests/psxreaddir/test.c
@@ -371,7 +371,13 @@ int main(
rtems_test_assert ( status == 0 );
printf("opendir, readdir and closedir %s\n", my_file);
+#ifdef O_DIRECTORY
+ fd = open( my_file, O_RDONLY );
+ rtems_test_assert( fd >= 0 );
+ directory_not = fdopendir( fd );
+#else
directory_not = opendir (my_file);
+#endif
rtems_test_assert( directory_not != NULL );
d_not = readdir(directory_not);
rtems_test_assert( d_not == NULL );
More information about the vc
mailing list