projects
/
mmh
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Signed-off-by: Ken Hornstein <kenh@pobox.com>
[mmh]
/
sbr
/
m_mktemp.c
diff --git
a/sbr/m_mktemp.c
b/sbr/m_mktemp.c
index
2229036
..
aa25636
100644
(file)
--- a/
sbr/m_mktemp.c
+++ b/
sbr/m_mktemp.c
@@
-1,8
+1,6
@@
/*
* m_mktemp.c -- Construct a temporary file.
*
/*
* m_mktemp.c -- Construct a temporary file.
*
- * $Id$
- *
* This code is Copyright (c) 2010, by the authors of nmh. See the
* COPYRIGHT file in the root directory of the nmh distribution for
* complete copyright information.
* This code is Copyright (c) 2010, by the authors of nmh. See the
* COPYRIGHT file in the root directory of the nmh distribution for
* complete copyright information.
@@
-109,6
+107,7
@@
m_mktemp2 (
{
static char buffer[BUFSIZ];
char *cp;
{
static char buffer[BUFSIZ];
char *cp;
+ int n;
if (dir_in == NULL) {
if (pfx_in == NULL) {
if (dir_in == NULL) {
if (pfx_in == NULL) {
@@
-122,7
+121,7
@@
m_mktemp2 (
/* No directory component */
return m_mktemp(pfx_in, fd_ret, fp_ret);
}
/* No directory component */
return m_mktemp(pfx_in, fd_ret, fp_ret);
}
- int n = (int)(cp-dir_in-1); /* Length of dir component */
+ n = (int)(cp-dir_in-1); /* Length of dir component */
snprintf(buffer, sizeof(buffer), "%.*s%s", n, dir_in, pfx_in);
return m_mktemp(buffer, fd_ret, fp_ret);
}
snprintf(buffer, sizeof(buffer), "%.*s%s", n, dir_in, pfx_in);
return m_mktemp(buffer, fd_ret, fp_ret);
}