]> granicus.if.org Git - postgresql/commitdiff
initdb didn't always remove temp file
authorPeter Eisentraut <peter_e@gmx.net>
Tue, 25 Apr 2000 08:29:02 +0000 (08:29 +0000)
committerPeter Eisentraut <peter_e@gmx.net>
Tue, 25 Apr 2000 08:29:02 +0000 (08:29 +0000)
src/bin/initdb/initdb.sh

index b4d0f9d2d9e30ca2240f3a0148ed5970c92d8331..3712a7a38a96180f28c3475fa4857f23c7e8c2eb 100644 (file)
@@ -26,7 +26,7 @@
 #
 #
 # IDENTIFICATION
-#    $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.90 2000/04/08 18:35:29 momjian Exp $
+#    $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.91 2000/04/25 08:29:02 petere Exp $
 #
 #-------------------------------------------------------------------------
 
@@ -476,10 +476,7 @@ then
     "$PGPATH"/postgres $BACKENDARGS template1 < "$TEMPFILE"
     # Gotta remove that temp file before exiting on error.
     retval="$?"
-    if [ "$noclean" -eq 0 ]
-    then
-            rm -f "$TEMPFILE" || exit_nicely
-    fi
+    rm -f "$TEMPFILE" || exit_nicely
     [ "$retval" -ne 0 ] && exit_nicely
 fi
 
@@ -596,10 +593,7 @@ cat "$GLOBAL_DESCR" >> $TEMPFILE
 
 cat $TEMPFILE \
        | "$PGPATH"/postgres $PGSQL_OPT template1 > /dev/null || exit_nicely
-if [ "$noclean" -eq 0 ]
-then
-    rm -f "$TEMPFILE" || exit_nicely
-fi
+rm -f "$TEMPFILE" || exit_nicely
 
 echo "Vacuuming database."
 echo "VACUUM ANALYZE" \