aboutsummaryrefslogtreecommitdiff
path: root/tests/test_conda.c
diff options
context:
space:
mode:
authorJoseph Hunkeler <jhunkeler@gmail.com>2024-11-01 00:55:19 -0400
committerJoseph Hunkeler <jhunkeler@gmail.com>2024-11-01 08:35:19 -0400
commit35d0480f743abaa5c2c332f513043edd7c59081c (patch)
tree0e4071402281e44e492df78292002adad0c997d2 /tests/test_conda.c
parentd4cbcbfb77476ba8f21b82c608322af80cd6a303 (diff)
downloadstasis-35d0480f743abaa5c2c332f513043edd7c59081c.tar.gz
Initialize structs to {0} and combine declaration and assignment where possible
Diffstat (limited to 'tests/test_conda.c')
-rw-r--r--tests/test_conda.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/test_conda.c b/tests/test_conda.c
index 84f98bc..63a2781 100644
--- a/tests/test_conda.c
+++ b/tests/test_conda.c
@@ -202,7 +202,11 @@ int main(int argc, char *argv[]) {
test_delivery_gather_tool_versions,
};
- const char *ws = "workspace";
+ char ws[] = "workspace_XXXXXX";
+ if (!mkdtemp(ws)) {
+ perror("mkdtemp");
+ exit(1);
+ }
getcwd(cwd_start, sizeof(cwd_start) - 1);
mkdir(ws, 0755);
chdir(ws);