From: David van Moolenbroek Date: Wed, 28 Dec 2016 12:53:10 +0000 (+0000) Subject: test74: allow to be run from source directory X-Git-Url: http://zhaoyanbai.com/repos/zlib_tech.html?a=commitdiff_plain;h=refs%2Fchanges%2F80%2F3380%2F1;p=minix.git test74: allow to be run from source directory A small fix to allow this test to be run from its original source directory location, in addition to its installed location. Change-Id: I4b7afed14ba02b1bea8d9c5f65bc96698a279188 --- diff --git a/minix/tests/test74.c b/minix/tests/test74.c index 8a3ab0a59..e9733d29c 100644 --- a/minix/tests/test74.c +++ b/minix/tests/test74.c @@ -395,7 +395,9 @@ static void basic_regression(void) */ fd1 = open("../testsh1", O_RDONLY); + if (fd1 < 0) fd1 = open("../testsh1.sh", O_RDONLY); fd2 = open("../testsh2", O_RDONLY); + if (fd2 < 0) fd2 = open("../testsh2.sh", O_RDONLY); if(fd1 < 0 || fd2 < 0) { e(2); } /* just check that we can't mmap() a file writable */