aboutsummaryrefslogtreecommitdiff
path: root/lib/manifest.c
diff options
context:
space:
mode:
authorJoseph Hunkeler <jhunkeler@gmail.com>2020-04-18 23:50:52 -0400
committerJoseph Hunkeler <jhunkeler@gmail.com>2020-04-18 23:50:52 -0400
commit262a399beb9c525633d5ac96d15754faeb65a28c (patch)
treeffb98ee034d8f3a08366041ea2bd596c0c15986f /lib/manifest.c
parente0af560cabe6343e38061884c8361daddb5c7545 (diff)
downloadspmc-262a399beb9c525633d5ac96d15754faeb65a28c.tar.gz
spm_mkdtemp requires a base directory:
* test_spm_mkdtemp revealed a difference in how variables are stored (Linux vs. MacOS)
Diffstat (limited to 'lib/manifest.c')
-rw-r--r--lib/manifest.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/manifest.c b/lib/manifest.c
index 2d306e7..a95b566 100644
--- a/lib/manifest.c
+++ b/lib/manifest.c
@@ -75,7 +75,7 @@ Manifest *manifest_from(const char *package_dir) {
strncpy(info->origin, package_dir, SPM_PACKAGE_MEMBER_ORIGIN_SIZE);
- char *tmpdir = spm_mkdtemp("spm_manifest_from", NULL);
+ char *tmpdir = spm_mkdtemp(TMP_DIR, "spm_manifest_from", NULL);
if (!tmpdir) {
perror("failed to create temporary directory");
fprintf(SYSERROR);
@@ -390,7 +390,7 @@ Manifest *manifest_read(char *file_or_url) {
strcpy(path, SPM_GLOBAL.package_dir);
}
else {
- tmpdir = spm_mkdtemp("spm_manifest_read_XXXXXX", SPM_GLOBAL.repo_target);
+ tmpdir = spm_mkdtemp(TMP_DIR, "spm_manifest_read_XXXXXX", SPM_GLOBAL.repo_target);
if (exists(tmpdir) != 0) {
fprintf(stderr, "Failed to create temporary storage directory\n");
fprintf(SYSERROR);