Cygwin: testsuite: In pathconf01 use the temporary directory instead of "/tmp"

In pathconf01 use the temporary directory, instead of "/tmp" (which may not exist).
This commit is contained in:
Jon Turney 2020-11-27 15:18:37 +00:00
parent f1d7ef46f7
commit 6e843f7750
No known key found for this signature in database
GPG Key ID: C7C86F0370285C81
1 changed files with 7 additions and 1 deletions

View File

@ -117,6 +117,7 @@
extern void setup();
extern void cleanup();
extern char *TESTDIR;
@ -127,7 +128,7 @@ extern int Tst_count; /* Test Case counter for tst_* routines */
int exp_enos[]={0, 0};
int i;
const char *path = "/tmp";
const char *path;
struct pathconf_args
{
@ -157,6 +158,9 @@ main(int ac, char **av)
if ( (msg=parse_opts(ac, av, (option_t *) NULL, NULL)) != (char *) NULL )
tst_brkm(TBROK, cleanup, "OPTION PARSING ERROR - %s", msg);
tst_tmpdir();
path = TESTDIR;
/***************************************************************
* perform global setup for test
***************************************************************/
@ -208,6 +212,8 @@ main(int ac, char **av)
/***************************************************************
* cleanup and exit
***************************************************************/
tst_rmdir();
cleanup();
return 0;