summaryrefslogtreecommitdiffstats
path: root/app-text/a2ps/files/a2ps-4.13c-fixps.patch
blob: 13b196f03e7e55b2efbca0dd8260c9de653f14f9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
--- contrib/fixps.in.orig	2004-12-20 00:11:40.000000000 +0100
+++ contrib/fixps.in	2004-12-20 00:14:12.000000000 +0100
@@ -38,7 +38,7 @@
 run_gs=0
 # What action to perform: fixps, cat, check, and gs
 task=fixps
-tmpdir=/tmp/$program.$$
+tmpdir=`mktemp -d -t fixps.XXXXXX` || { echo "$program: Cannot create temporary dir!" >&2 ; exit 1; }
 verbose=echo
 
 # The version/usage strings
@@ -191,7 +191,6 @@
   trap "/bin/rm -rf $tmpdir" 0 1 2 3 13 15
 fi
 
-mkdir $tmpdir
 fixps_sed=$tmpdir/fixps.sed
 
 # If printing from stdin, save into a tmp file