summaryrefslogtreecommitdiff
path: root/src/share/common
diff options
context:
space:
mode:
authorJameson Graef Rollins <jrollins@finestructure.net>2009-02-18 20:56:14 -0500
committerJameson Graef Rollins <jrollins@finestructure.net>2009-02-18 20:56:14 -0500
commit62374dd1c16a2719202955ad3fe878be5cc14dba (patch)
treeb2d4480ad337ee204719b180613c58e21c7ca392 /src/share/common
parent88b19565bced6d9ec9b035d1f9fe51ce6567923b (diff)
new msmktempdir function, to simplify making temporary directories. remove MHTMPDIR, since it's not needed.
Diffstat (limited to 'src/share/common')
-rw-r--r--src/share/common5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/share/common b/src/share/common
index 4120259..6b7d51b 100644
--- a/src/share/common
+++ b/src/share/common
@@ -134,6 +134,11 @@ cutline() {
head --line="$1" "$2" | tail -1
}
+# make a temporary directly
+msmktempdir() {
+ mktemp -d ${TMPDIR:-/tmp}/tmp.XXXXXXXXXX
+}
+
# this is a wrapper for doing lock functions.
#
# it lets us depend on either lockfile-progs (preferred) or procmail's