aboutsummaryrefslogtreecommitdiff
path: root/lib/manifest.c
diff options
context:
space:
mode:
authorJoseph Hunkeler <jhunkeler@users.noreply.github.com>2020-04-18 23:54:54 -0400
committerGitHub <noreply@github.com>2020-04-18 23:54:54 -0400
commit59f7d29e2d707373ba1153337dca3279a2e3acc5 (patch)
treeffb98ee034d8f3a08366041ea2bd596c0c15986f /lib/manifest.c
parente0af560cabe6343e38061884c8361daddb5c7545 (diff)
parent262a399beb9c525633d5ac96d15754faeb65a28c (diff)
downloadspmc-59f7d29e2d707373ba1153337dca3279a2e3acc5.tar.gz
Merge pull request #26 from jhunkeler/fix_spm_mkdtemp
spm_mkdtemp requires a base directory:
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);