diff options
author | jlam <jlam> | 2006-01-24 15:26:06 +0000 |
---|---|---|
committer | jlam <jlam> | 2006-01-24 15:26:06 +0000 |
commit | c1a9a6136bd05c76ac4480c359121e3d19cf60bd (patch) | |
tree | 23b11164d66a8646c41866be91e644f695a5cb06 /mk/scripts/extract | |
parent | af22716fa086795a836fd4be56158f07d6aefe39 (diff) | |
download | pkgsrc-c1a9a6136bd05c76ac4480c359121e3d19cf60bd.tar.gz |
Ensure that decompress_cat and tarprog always have vaild default values
in the case where the user makes bad option choices on the command line.
Diffstat (limited to 'mk/scripts/extract')
-rwxr-xr-x | mk/scripts/extract | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/mk/scripts/extract b/mk/scripts/extract index db8db094f9b..c5af6d6e17e 100755 --- a/mk/scripts/extract +++ b/mk/scripts/extract @@ -1,6 +1,6 @@ #!/bin/sh # -# $NetBSD: extract,v 1.15 2006/01/23 17:52:02 wiz Exp $ +# $NetBSD: extract,v 1.16 2006/01/24 15:26:06 jlam Exp $ # # Copyright (c) 2006 The NetBSD Foundation, Inc. # All rights reserved. @@ -146,6 +146,7 @@ case "$extract_using" in /*tar|/*pax) tarprog="$extract_using" ;; *tar) tarprog="${TAR}" ;; *pax) tarprog="${PAX}" ;; +*) tarprog="${TAR}" ;; esac if ${TEST} -n "$exclude_file" -a ! -f "$exclude_file"; then @@ -162,7 +163,7 @@ case "$distfile" in *.gz|*.tgz|*.z) decompress_cat="${GZCAT}" ;; *.bz2|*.tbz|*.tbz2) decompress_cat="${BZCAT}" ;; *.Z) decompress_cat="${GZCAT}" ;; --) decompress_cat="${CAT}" ;; +*) decompress_cat="${CAT}" ;; esac # Derive the format of the archive based on the file extension. |