summaryrefslogtreecommitdiffstats
path: root/hl/test/test_lite.c
diff options
context:
space:
mode:
Diffstat (limited to 'hl/test/test_lite.c')
-rw-r--r--hl/test/test_lite.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/hl/test/test_lite.c b/hl/test/test_lite.c
index 2012e8f..27da0ab 100644
--- a/hl/test/test_lite.c
+++ b/hl/test/test_lite.c
@@ -1538,18 +1538,10 @@ static int test_complicated_compound(void)
char *line = NULL;
FILE *fp = NULL;
size_t size = 1024;
- char *srcdir = getenv("srcdir"); /* the source directory */
- char filename[1024]="";
+ const char *filename = H5_get_srcdir_filename(INPUT_FILE);
TESTING3(" text for complicated compound types");
- /* compose the name of the file to open, using the srcdir, if appropriate */
- if(srcdir) {
- strcpy(filename, srcdir);
- strcat(filename, "/");
- }
- strcat(filename, INPUT_FILE);
-
/* Open input file */
fp = fopen(filename, "r");
if(fp == NULL) {