From ce8363d3636487339c5c16d914523766812110fa Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Wed, 11 Dec 2013 10:23:44 +0100 Subject: sptests/spfifo01: Add test case for mknod() --- testsuites/sptests/spfifo01/init.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/testsuites/sptests/spfifo01/init.c b/testsuites/sptests/spfifo01/init.c index 9128a678e4..9bc42e06f5 100644 --- a/testsuites/sptests/spfifo01/init.c +++ b/testsuites/sptests/spfifo01/init.c @@ -26,10 +26,8 @@ rtems_task Init(rtems_task_argument argument); static void test_main(void) { - int status = -1; - int fd; - char buf [1]; - ssize_t n; + mode_t rwx = S_IRWXU | S_IRWXG | S_IRWXO; + int status; puts("\n\n*** FIFO / PIPE OPEN TEST - 1 ***"); @@ -40,7 +38,12 @@ static void test_main(void) ); errno = 0; - status = mkfifo(FIFO_PATH, 0777); + status = mkfifo(FIFO_PATH, rwx); + rtems_test_assert(status == -1); + rtems_test_assert(errno == ENOSYS); + + errno = 0; + status = mknod(FIFO_PATH, S_IFIFO | rwx, 0); rtems_test_assert(status == -1); rtems_test_assert(errno == ENOSYS); -- cgit v1.2.3