projects
/
mmh
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add some gcc hint defines
[mmh]
/
sbr
/
m_mktemp.c
diff --git
a/sbr/m_mktemp.c
b/sbr/m_mktemp.c
index
4a1eed1
..
ff5d00c
100644
(file)
--- a/
sbr/m_mktemp.c
+++ b/
sbr/m_mktemp.c
@@
-6,8
+6,10
@@
** complete copyright information.
*/
** complete copyright information.
*/
-#include <errno.h>
#include <h/mh.h>
#include <h/mh.h>
+#include <errno.h>
+#include <unistd.h>
+#include <sys/stat.h>
static char *get_temp_dir();
static char *get_temp_dir();
@@
-124,7
+126,7
@@
m_mktemp2(
return m_mktemp(pfx_in, fd_ret, fp_ret);
}
n = (int)(cp-dir_in-1); /* Length of dir component */
return m_mktemp(pfx_in, fd_ret, fp_ret);
}
n = (int)(cp-dir_in-1); /* Length of dir component */
- snprintf(buffer, sizeof(buffer), "%.*s%s", n, dir_in, pfx_in);
+ snprintf(buffer, sizeof(buffer), "%.*s/%s", n, dir_in, pfx_in);
return m_mktemp(buffer, fd_ret, fp_ret);
}
return m_mktemp(buffer, fd_ret, fp_ret);
}