summaryrefslogtreecommitdiffstats
path: root/test/test_string.c
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2024-07-16 22:14:26 -0400
committerDavid Robillard <d@drobilla.net>2024-07-16 22:14:26 -0400
commit8112aeb6df18d2cba00212a0b036f8e51ae7c891 (patch)
treec4f8646847d1eb8918c2d926454b8dcdbbfc8193 /test/test_string.c
parentd3b2131441d2846a1d123defc2493a6fcf996cff (diff)
downloadlilv-8112aeb6df18d2cba00212a0b036f8e51ae7c891.tar.gz
lilv-8112aeb6df18d2cba00212a0b036f8e51ae7c891.tar.bz2
lilv-8112aeb6df18d2cba00212a0b036f8e51ae7c891.zip
Avoid use of clobbered environment in test
Diffstat (limited to 'test/test_string.c')
-rw-r--r--test/test_string.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/test_string.c b/test/test_string.c
index 48021ed..028b7da 100644
--- a/test/test_string.c
+++ b/test/test_string.c
@@ -21,10 +21,10 @@ main(void)
#ifndef _WIN32
char* s = NULL;
- const char* const home = getenv("HOME");
-
setenv("LILV_TEST_1", "test", 1);
+ const char* const home = getenv("HOME");
+
assert(!strcmp((s = lilv_expand("$LILV_TEST_1")), "test"));
free(s);
if (home) {