summaryrefslogtreecommitdiff
path: root/misc/mc/files/patch-vfs-extfs
diff options
context:
space:
mode:
Diffstat (limited to 'misc/mc/files/patch-vfs-extfs')
-rw-r--r--misc/mc/files/patch-vfs-extfs351
1 files changed, 351 insertions, 0 deletions
diff --git a/misc/mc/files/patch-vfs-extfs b/misc/mc/files/patch-vfs-extfs
new file mode 100644
index 000000000000..3712d74eae7e
--- /dev/null
+++ b/misc/mc/files/patch-vfs-extfs
@@ -0,0 +1,351 @@
+--- vfs/extfs/deb.in.orig Thu Dec 12 02:57:00 2002
++++ vfs/extfs/deb.in Tue Jun 15 03:15:09 2004
+@@ -149,15 +149,10 @@
+ }
+ else
+ {
+- $suffix = "aaa";
+- while (1) {
+- $tmpdir = "/tmp/mcdebfs.run".$$.$suffix;
+- last if mkdir $tmpdir, 0700;
+- $suffix++;
+- # Somebody is being really nasty, give up
+- exit 1 if $suffix eq "zzz";
+- }
+-
++ use File::Temp qw(mkdtemp);
++ my $template = "/tmp/mcdebfs.run.XXXXXX";
++ $template="$ENV{MC_TMPDIR}/mcdebfs.XXXXXX" if ($ENV{MC_TMPDIR});
++ $tmpdir = mkdtemp($template);
+ $tmpcmd="$tmpdir/run";
+ &mcdebfs_copyout($archive, $filename, $tmpcmd);
+ system("chmod u+x $tmpcmd");
+--- vfs/extfs/rpm.orig Sun Dec 29 15:19:39 2002
++++ vfs/extfs/rpm Tue Jun 15 03:25:41 2004
+@@ -1,14 +1,17 @@
+ #! /bin/sh
+ #
+ # Written by Erik Troan (ewt@redhat.com) 1996
+-# Jakub Jelinek (jj@sunsite.mff.cuni.cz) 1996
++# Jakub Jelinek (jj@sunsite.mff.cuni.cz) 1996, 2004
+ # Tomasz Kłoczko (kloczek@rudy.mif.pg.gda.pl) 1997
+ # minor changes by Wojtek Pilorz (wpilorz@bdk.lublin.pl) 1997
+ # minor changes by Michele Marziani (marziani@fe.infn.it) 1997
+ # bug files by Marc Merlin (marcsoft@merlins.org) 1998
+ # locale bugfix by Michal Svec (rebel@penguin.cz) 2000
+-# (C) 1996 The Free Software Foundation.
++# Whitespace(s) & single quote(s) in filename workaround
++# by Andrew V. Samoilov <sav@bcs.zp.ua> 2004
++# https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=64007
+ #
++# (C) 1996-2004 The Free Software Foundation.
+ #
+
+ # override any locale for dates
+@@ -22,6 +25,10 @@
+ RPM="rpm"
+ fi
+ RPM2CPIO="rpm2cpio"
++SED=sed
++# Surround the whole filename with single quotes and handle specially
++# \', ' and \ at the end of the string.
++SEDCMD="s/\\(\\\\\\?\\)'/'\\1\\1\\\\''/g;s/\\\\\$/'\\\\\\\\'/;s/^/'/;s/\$/'/"
+
+ mcrpmfs_list ()
+ {
+@@ -31,12 +38,13 @@
+ if test -z "$MCFASTRPM"; then
+ MCFASTRPM=$MCFASTRPM_DFLT
+ fi
++ f="`echo "$1" | $SED "$SEDCMD"`"
+ FILEPREF="-r--r--r-- 1 root root "
+- DESC=`$RPM -qip "$1" 2>/dev/null` || {
++ DESC=`$RPM -qip "$f" 2>/dev/null` || {
+ echo "$FILEPREF 0 "`date +"%b %d %H:%M"`" ERROR"
+ exit 1
+ }
+- DATE=`$RPM -qp --qf "%{BUILDTIME:date}\n" "$1" | cut -c 5-11,21-24`
++ DATE=`$RPM -qp --qf "%{BUILDTIME:date}\n" "$f" | cut -c 5-11,21-24`
+ HEADERSIZE=`echo "$DESC" | wc -c`
+ echo "-r--r--r-- 1 root root $HEADERSIZE $DATE HEADER"
+ echo "-r-xr-xr-x 1 root root 39 $DATE INSTALL"
+@@ -47,25 +55,25 @@
+ echo "$FILEPREF 0 $DATE INFO/BUILDHOST"
+ echo "$FILEPREF 0 $DATE INFO/SOURCERPM"
+ if test "$MCFASTRPM" = 0 ; then
+- test "`$RPM -qp --qf \"%{DISTRIBUTION}\" \"$1\"`" = "(none)" ||
++ test "`$RPM -qp --qf \"%{DISTRIBUTION}\" \"$f\"`" = "(none)" ||
+ echo "$FILEPREF 0 $DATE INFO/DISTRIBUTION"
+- test "`$RPM -qp --qf \"%{VENDOR}\" \"$1\"`" = "(none)" ||
++ test "`$RPM -qp --qf \"%{VENDOR}\" \"$f\"`" = "(none)" ||
+ echo "$FILEPREF 0 $DATE INFO/VENDOR"
+- test "`$RPM -qp --qf \"%{DESCRIPTION}\" \"$1\"`" = "(none)" ||
++ test "`$RPM -qp --qf \"%{DESCRIPTION}\" \"$f\"`" = "(none)" ||
+ echo "$FILEPREF 0 $DATE INFO/DESCRIPTION"
+- test "`$RPM -qp --qf \"%{SUMMARY}\" \"$1\"`" = "(none)" ||
++ test "`$RPM -qp --qf \"%{SUMMARY}\" \"$f\"`" = "(none)" ||
+ echo "$FILEPREF 0 $DATE INFO/SUMMARY"
+- if test "`$RPM -qp --qf \"%{RPMTAG_PREIN}%{RPMTAG_POSTIN}%{RPMTAG_PREUN}%{RPMTAG_POSTUN}%{VERIFYSCRIPT}\" \"$1\"`" != "(none)(none)(none)(none)(none)"; then
++ if test "`$RPM -qp --qf \"%{RPMTAG_PREIN}%{RPMTAG_POSTIN}%{RPMTAG_PREUN}%{RPMTAG_POSTUN}%{VERIFYSCRIPT}\" \"$f\"`" != "(none)(none)(none)(none)(none)"; then
+ echo "dr-xr-xr-x 1 root root 0 $DATE INFO/SCRIPTS"
+- test "`$RPM -qp --qf \"%{RPMTAG_PREIN}\" \"$1\"`" = '(none)' ||
++ test "`$RPM -qp --qf \"%{RPMTAG_PREIN}\" \"$f\"`" = '(none)' ||
+ echo "$FILEPREF 0 $DATE INFO/SCRIPTS/PREIN"
+- test "`$RPM -qp --qf \"%{RPMTAG_POSTIN}\" \"$1\"`" = '(none)' ||
++ test "`$RPM -qp --qf \"%{RPMTAG_POSTIN}\" \"$f\"`" = '(none)' ||
+ echo "$FILEPREF 0 $DATE INFO/SCRIPTS/POSTIN"
+- test "`$RPM -qp --qf \"%{RPMTAG_PREUN}\" \"$1\"`" = '(none)' ||
++ test "`$RPM -qp --qf \"%{RPMTAG_PREUN}\" \"$f\"`" = '(none)' ||
+ echo "$FILEPREF 0 $DATE INFO/SCRIPTS/PREUN"
+- test "`$RPM -qp --qf \"%{RPMTAG_POSTUN}\" \"$1\"`" = '(none)' ||
++ test "`$RPM -qp --qf \"%{RPMTAG_POSTUN}\" \"$f\"`" = '(none)' ||
+ echo "$FILEPREF 0 $DATE INFO/SCRIPTS/POSTUN"
+- test "`$RPM -qp --qf \"%{VERIFYSCRIPT}\" \"$1\"`" = '(none)' ||
++ test "`$RPM -qp --qf \"%{VERIFYSCRIPT}\" \"$f\"`" = '(none)' ||
+ echo "$FILEPREF 0 $DATE INFO/SCRIPTS/VERIFYSCRIPT"
+ echo "$FILEPREF 0 $DATE INFO/SCRIPTS/ALL"
+ fi
+@@ -83,15 +91,15 @@
+ echo "$FILEPREF 0 $DATE INFO/SCRIPTS/ALL"
+ fi
+ if test "$MCFASTRPM" = 0 ; then
+- test "`$RPM -qp --qf \"%{PACKAGER}\" \"$1\"`" = "(none)" ||
++ test "`$RPM -qp --qf \"%{PACKAGER}\" \"$f\"`" = "(none)" ||
+ echo "$FILEPREF 0 $DATE INFO/PACKAGER"
+- test "`$RPM -qp --qf \"%{URL}\" \"$1\"`" = "(none)" ||
++ test "`$RPM -qp --qf \"%{URL}\" \"$f\"`" = "(none)" ||
+ echo "$FILEPREF 0 $DATE INFO/URL"
+- test "`$RPM -qp --qf \"%{SERIAL}\" \"$1\"`" = "(none)" ||
++ test "`$RPM -qp --qf \"%{SERIAL}\" \"$f\"`" = "(none)" ||
+ echo "$FILEPREF 0 $DATE INFO/SERIAL"
+- test "`$RPM -qp --qf \"%{COPYRIGHT}\" \"$1\"`" = "(none)" ||
++ test "`$RPM -qp --qf \"%{COPYRIGHT}\" \"$f\"`" = "(none)" ||
+ echo "$FILEPREF 0 $DATE INFO/COPYRIGHT"
+- test "`$RPM -qp --qf \"%{LICENSE}\" \"$1\"`" = "(none)" ||
++ test "`$RPM -qp --qf \"%{LICENSE}\" \"$f\"`" = "(none)" ||
+ echo "$FILEPREF 0 $DATE INFO/LICENSE"
+ else
+ echo "$FILEPREF 0 $DATE INFO/PACKAGER"
+@@ -105,13 +113,13 @@
+ echo "$FILEPREF 0 $DATE INFO/OS"
+ echo "$FILEPREF 0 $DATE INFO/SIZE"
+ if test "$MCFASTRPM" != 0 ; then
+- $RPM -qp --qf "[%{REQUIRENAME}\n]" "$1" | grep "(none)" > /dev/null ||
++ $RPM -qp --qf "[%{REQUIRENAME}\n]" "$f" | grep "(none)" > /dev/null ||
+ echo "$FILEPREF 0 $DATE INFO/REQUIRENAME"
+- $RPM -qp --qf "[%{OBSOLETES}\n]" "$1" | grep "(none)" > /dev/null ||
++ $RPM -qp --qf "[%{OBSOLETES}\n]" "$f" | grep "(none)" > /dev/null ||
+ echo "$FILEPREF 0 $DATE INFO/OBSOLETES"
+- $RPM -qp --qf "[%{PROVIDES}\n]" "$1" | grep "(none)" > /dev/null ||
++ $RPM -qp --qf "[%{PROVIDES}\n]" "$f" | grep "(none)" > /dev/null ||
+ echo "$FILEPREF 0 $DATE INFO/PROVIDES"
+- test "`$RPM -qp --qf \"%{CHANGELOGTEXT}\" \"$1\"`" = "(none)" ||
++ test "`$RPM -qp --qf \"%{CHANGELOGTEXT}\" \"$f\"`" = "(none)" ||
+ echo "$FILEPREF 0 $DATE INFO/CHANGELOG"
+ else
+ echo "$FILEPREF 0 $DATE INFO/REQUIRENAME"
+@@ -120,61 +128,55 @@
+ echo "$FILEPREF 0 $DATE INFO/CHANGELOG"
+ fi
+
+- $RPM2CPIO "$1" | cpio -tv --quiet
+ echo "$FILEPREF 0 $DATE CONTENTS.cpio"
+ }
+
+ mcrpmfs_copyout ()
+ {
++ f="`echo "$1" | $SED "$SEDCMD"`"
+ case "$2" in
+- HEADER) $RPM -qip "$1" > "$3"; exit 0;;
++ HEADER) $RPM -qip "$f" > "$3"; exit 0;;
+ INSTALL) echo "# Run this to install this RPM package" > "$3"; exit 0;;
+ UPGRADE) echo "# Run this to upgrade this RPM package" > "$3"; exit 0;;
+- ERROR) $RPM -qip "$1" > /dev/null 2> "$3"; exit 0;;
+- INFO/NAME-VERSION-RELEASE) $RPM -qp --qf "%{NAME}-%{VERSION}-%{RELEASE}\n" "$1" > "$3"; exit 0;;
+- INFO/RELEASE) $RPM -qp --qf "%{RELEASE}\n" "$1" > "$3"; exit 0;;
+- INFO/GROUP) $RPM -qp --qf "%{GROUP}\n" "$1" > "$3"; exit 0;;
+- INFO/DISTRIBUTION) $RPM -qp --qf "%{DISTRIBUTION}\n" "$1" > "$3"; exit 0;;
+- INFO/VENDOR) $RPM -qp --qf "%{VENDOR}\n" "$1" > "$3"; exit 0;;
+- INFO/BUILDHOST) $RPM -qp --qf "%{BUILDHOST}\n" "$1" > "$3"; exit 0;;
+- INFO/SOURCERPM) $RPM -qp --qf "%{SOURCERPM}\n" "$1" > "$3"; exit 0;;
+- INFO/DESCRIPTION) $RPM -qp --qf "%{DESCRIPTION}\n" "$1" > "$3"; exit 0;;
+- INFO/PACKAGER) $RPM -qp --qf "%{PACKAGER}\n" "$1" > "$3"; exit 0;;
+- INFO/URL) $RPM -qp --qf "%{URL}\n" "$1" >"$3"; exit 0;;
+- INFO/BUILDTIME) $RPM -qp --qf "%{BUILDTIME:date}\n" "$1" >"$3"; exit 0;;
+- INFO/SERIAL) $RPM -qp --qf "%{SERIAL}\n" "$1" >"$3"; exit 0;;
+- INFO/COPYRIGHT) $RPM -qp --qf "%{COPYRIGHT}\n" "$1" >"$3"; exit 0;;
+- INFO/RPMVERSION) $RPM -qp --qf "%{RPMVERSION}\n" "$1" >"$3"; exit 0;;
+- INFO/REQUIRENAME) $RPM -qp --qf "[%{REQUIRENAME} %{REQUIREFLAGS:depflags} %{REQUIREVERSION}\n]" "$1" >"$3"; exit 0;;
+- INFO/PROVIDES) $RPM -qp --qf "[%{PROVIDES}\n]" "$1" >"$3"; exit 0;;
+- INFO/SCRIPTS/PREIN) $RPM -qp --qf "%{RPMTAG_PREIN}\n" "$1" >"$3"; exit 0;;
+- INFO/SCRIPTS/POSTIN) $RPM -qp --qf "%{RPMTAG_POSTIN}\n" "$1" >"$3"; exit 0;;
+- INFO/SCRIPTS/PREUN) $RPM -qp --qf "%{RPMTAG_PREUN}\n" "$1" >"$3"; exit 0;;
+- INFO/SCRIPTS/POSTUN) $RPM -qp --qf "%{RPMTAG_POSTUN}\n" "$1" >"$3"; exit 0;;
+- INFO/SCRIPTS/VERIFYSCRIPT) $RPM -qp --qf "%{VERIFYSCRIPT}\n" "$1" >"$3"; exit 0;;
+- INFO/SCRIPTS/ALL) $RPM -qp --scripts "$1" > "$3"; exit 0;;
+- INFO/SUMMARY) $RPM -qp --qf "%{SUMMARY}\n" "$1" > "$3"; exit 0;;
+- INFO/OS) $RPM -qp --qf "%{OS}\n" "$1" > "$3"; exit 0;;
+- INFO/CHANGELOG) $RPM -qp --qf "[* %{CHANGELOGTIME:date} %{CHANGELOGNAME}\n%{CHANGELOGTEXT}\n\n]\n" "$1" > "$3"; exit 0;;
+- INFO/SIZE) $RPM -qp --qf "%{SIZE} bytes\n" "$1" > "$3"; exit 0;;
++ ERROR) $RPM -qip "$f" > /dev/null 2> "$3"; exit 0;;
++ INFO/NAME-VERSION-RELEASE) $RPM -qp --qf "%{NAME}-%{VERSION}-%{RELEASE}\n" "$f" > "$3"; exit 0;;
++ INFO/RELEASE) $RPM -qp --qf "%{RELEASE}\n" "$f" > "$3"; exit 0;;
++ INFO/GROUP) $RPM -qp --qf "%{GROUP}\n" "$f" > "$3"; exit 0;;
++ INFO/DISTRIBUTION) $RPM -qp --qf "%{DISTRIBUTION}\n" "$f" > "$3"; exit 0;;
++ INFO/VENDOR) $RPM -qp --qf "%{VENDOR}\n" "$f" > "$3"; exit 0;;
++ INFO/BUILDHOST) $RPM -qp --qf "%{BUILDHOST}\n" "$f" > "$3"; exit 0;;
++ INFO/SOURCERPM) $RPM -qp --qf "%{SOURCERPM}\n" "$f" > "$3"; exit 0;;
++ INFO/DESCRIPTION) $RPM -qp --qf "%{DESCRIPTION}\n" "$f" > "$3"; exit 0;;
++ INFO/PACKAGER) $RPM -qp --qf "%{PACKAGER}\n" "$f" > "$3"; exit 0;;
++ INFO/URL) $RPM -qp --qf "%{URL}\n" "$f" >"$3"; exit 0;;
++ INFO/BUILDTIME) $RPM -qp --qf "%{BUILDTIME:date}\n" "$f" >"$3"; exit 0;;
++ INFO/SERIAL) $RPM -qp --qf "%{SERIAL}\n" "$f" >"$3"; exit 0;;
++ INFO/COPYRIGHT) $RPM -qp --qf "%{COPYRIGHT}\n" "$f" >"$3"; exit 0;;
++ INFO/RPMVERSION) $RPM -qp --qf "%{RPMVERSION}\n" "$f" >"$3"; exit 0;;
++ INFO/REQUIRENAME) $RPM -qp --qf "[%{REQUIRENAME} %{REQUIREFLAGS:depflags} %{REQUIREVERSION}\n]" "$f" >"$3"; exit 0;;
++ INFO/PROVIDES) $RPM -qp --qf "[%{PROVIDES}\n]" "$f" >"$3"; exit 0;;
++ INFO/SCRIPTS/PREIN) $RPM -qp --qf "%{RPMTAG_PREIN}\n" "$f" >"$3"; exit 0;;
++ INFO/SCRIPTS/POSTIN) $RPM -qp --qf "%{RPMTAG_POSTIN}\n" "$f" >"$3"; exit 0;;
++ INFO/SCRIPTS/PREUN) $RPM -qp --qf "%{RPMTAG_PREUN}\n" "$f" >"$3"; exit 0;;
++ INFO/SCRIPTS/POSTUN) $RPM -qp --qf "%{RPMTAG_POSTUN}\n" "$f" >"$3"; exit 0;;
++ INFO/SCRIPTS/VERIFYSCRIPT) $RPM -qp --qf "%{VERIFYSCRIPT}\n" "$f" >"$3"; exit 0;;
++ INFO/SCRIPTS/ALL) $RPM -qp --scripts "$f" > "$3"; exit 0;;
++ INFO/SUMMARY) $RPM -qp --qf "%{SUMMARY}\n" "$f" > "$3"; exit 0;;
++ INFO/OS) $RPM -qp --qf "%{OS}\n" "$f" > "$3"; exit 0;;
++ INFO/CHANGELOG) $RPM -qp --qf "[* %{CHANGELOGTIME:date} %{CHANGELOGNAME}\n%{CHANGELOGTEXT}\n\n]\n" "$f" > "$3"; exit 0;;
++ INFO/SIZE) $RPM -qp --qf "%{SIZE} bytes\n" "$f" > "$3"; exit 0;;
+ CONTENTS.cpio) $RPM2CPIO "$1" > "$3"; exit 0;;
+ *)
+- TMPDIR=/tmp/mctmpdir.$$
+- mkdir $TMPDIR || exit 1
+- cd $TMPDIR
+- # Files in RPM version 4 and above start with "./" - try both
+- $RPM2CPIO "$1" | cpio -iumd --quiet "$2" "./$2" >/dev/null
+- mv "$2" "$3" 2>/dev/null
+- cd /
+- rm -rf $TMPDIR;;
++ ;;
+ esac
+ }
+
+ mcrpmfs_run ()
+ {
++ f="`echo "$1" | $SED "$SEDCMD"`"
+ case "$2" in
+- INSTALL) echo "Installing \"$1\""; $RPM -ivh "$1"; exit 0;;
+- UPGRADE) echo "Upgrading \"$1\""; $RPM -iUvh "$1"; exit 0;;
++ INSTALL) echo "Installing \"$1\""; $RPM -ivh "$f"; exit 0;;
++ UPGRADE) echo "Upgrading \"$1\""; $RPM -Uvh "$f"; exit 0;;
+ esac
+ }
+
+--- vfs/extfs/uar.in.orig Thu Dec 12 15:21:35 2002
++++ vfs/extfs/uar.in Tue Jun 15 03:15:09 2004
+@@ -22,8 +22,7 @@
+
+ mcarfs_copyin ()
+ {
+- TMPDIR=/tmp/mctmpdir-uar.$$
+- mkdir $TMPDIR || exit 1
++ TMPDIR=`mktemp -d ${MC_TMPDIR:-/tmp}/mctmpdir-uar.XXXXXX` || exit 1
+ name=`basename "$2"`
+ (cd $TMPDIR && cp -fp "$3" $name && $XAR r "$1" $name)
+ rm -rf $TMPDIR
+--- vfs/extfs/uha.in.orig Sat Dec 14 11:10:53 2002
++++ vfs/extfs/uha.in Tue Jun 15 03:15:09 2004
+@@ -31,8 +31,7 @@
+
+ mchafs_copyout ()
+ {
+- TMPDIR="/tmp/mctmpdir-uha.$$"
+- mkdir $TMPDIR || exit 1
++ TMPDIR=`mktemp -d ${MC_TMPDIR:-/tmp}/mctmpdir-uha.XXXXXX` || exit 1
+ cd $TMPDIR
+
+ $HA xyq "$1" "$2" >/dev/null
+--- vfs/extfs/ulha.in.orig Sat Dec 14 10:39:10 2002
++++ vfs/extfs/ulha.in Tue Jun 15 03:15:09 2004
+@@ -35,12 +35,6 @@
+ LHA_GET="lha pq"
+ LHA_PUT="lha aq"
+
+-# Define a directory to create a temporary file for when
+-# running a command to be run from the archive
+-TMPDIR="/tmp/mctmpdir-uha.$$"
+-# Temporary file within the directory
+-TMPCMD=$TMPDIR/run
+-
+ # The 'list' command executive
+
+ mc_lha_fs_list()
+@@ -121,9 +115,9 @@
+
+ mc_lha_fs_run()
+ {
++ TMPDIR=`mktemp -d ${MC_TMPDIR:-/tmp}/mctmpdir-ulha.XXXXXX` || exit 1
+ trap "rm -rf $TMPDIR; exit 0" 1 2 3 4 15
+- # FIXME: Try harder to generate a unique directory if this fails
+- mkdir -m 0700 $TMPDIR || exit 1
++ TMPCMD=$TMPDIR/run
+ $LHA_GET "$1" "$2" > $TMPCMD
+ chmod a+x $TMPCMD
+ $TMPCMD
+--- vfs/extfs/urar.in.orig Fri Jan 24 21:56:25 2003
++++ vfs/extfs/urar.in Tue Jun 15 03:15:09 2004
+@@ -77,8 +77,7 @@
+ # preserve pwd. It is clean, but is it necessary?
+ pwd=`pwd`
+ # Create a directory and create in it a tmp directory with the good name
+- dir=tmpdir.${RANDOM}
+- mkdir $dir
++ dir=`mktemp -d ${MC_TMPDIR:-/tmp}/mctmpdir-urar.XXXXXX` || exit 1
+ cd $dir
+ mkdir -p "$2"
+ # rar cannot create an empty directory
+--- vfs/extfs/uzip.in.orig Thu Dec 12 15:15:20 2002
++++ vfs/extfs/uzip.in Tue Jun 15 03:18:53 2004
+@@ -76,7 +76,7 @@
+ sub mczipfs_rmdir {
+ my ($qfile) = map { &zipquotemeta($_) } @_;
+ &checkargs(1, 'archive directory', @_);
+- &safesystem("$cmd_delete $qarchive $qfile/ >/dev/null", 12);
++ &safesystem("$cmd_delete $qarchive $qfile/ >/dev/null 2>&1", 12);
+ exit;
+ }
+
+@@ -87,7 +87,7 @@
+ my ($qafile, $qfsfile) = map { &zipquotemeta($_) } @_;
+ &checkargs(1, 'archive file', @_);
+ &checkargs(2, 'local file', @_);
+- &safesystem("$cmd_extract $qarchive $qafile > $qfsfile", 11);
++ &safesystem("$cmd_extract $qarchive $qafile > $qfsfile 2>/dev/null", 11);
+ exit;
+ }
+
+@@ -344,10 +344,10 @@
+
+ # Make a temporary directory with mode 0700.
+ sub mktmpdir {
+- while (1) {
+- my $dir = POSIX::tmpnam();
+- return $dir if mkdir ($dir, 0700);
+- }
++ use File::Temp qw(mkdtemp);
++ my $template = "/tmp/mcuzipfs.XXXXXX";
++ $template="$ENV{MC_TMPDIR}/mcuzipfs.XXXXXX" if ($ENV{MC_TMPDIR});
++ return mkdtemp($template);
+ }
+
+ # Make a filename absolute and return it.
+--- vfs/extfs/uzoo.in.orig Sat Dec 14 10:29:13 2002
++++ vfs/extfs/uzoo.in Tue Jun 15 03:15:09 2004
+@@ -13,8 +13,7 @@
+ # it to a temporary directory.
+ mklink ()
+ {
+- TMPDIR="/tmp/mctmpdir-uzoo.$$"
+- mkdir $TMPDIR || exit 1
++ TMPDIR=`mktemp -d ${MC_TMPDIR:-/tmp}/mctmpdir-uzoo.XXXXXX` || exit 1
+ trap 'cd /; rm -rf $TMPDIR' 0 1 2 3 5 13 15
+ ARCHIVE=$TMPDIR/tmp.zoo
+ ln -sf "$1" "$ARCHIVE"