Skip to content

Commit

Permalink
Merge pull request #17 from atoomic/master
Browse files Browse the repository at this point in the history
Fix infinite loop when invoked incorrectly
  • Loading branch information
megastep committed Nov 29, 2012
2 parents 11216a7 + 5301d9c commit 2c60998
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions makeself-header.sh
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ EOLSM
--tar)
offset=\`head -n $SKIP "\$0" | wc -c | tr -d " "\`
arg1="\$2"
shift 2
if ! shift 2; then MS_Help; exit 1; fi
for s in \$filesizes
do
MS_dd "\$0" \$offset \$s | eval "$GUNZIP_CMD" | tar "\$arg1" - \$*
Expand All @@ -316,7 +316,7 @@ EOLSM
--target)
keep=y
targetdir=\${2:-.}
shift 2
if ! shift 2; then MS_Help; exit 1; fi
;;
--noprogress)
noprogress=y
Expand Down
12 changes: 6 additions & 6 deletions makeself.sh
Original file line number Diff line number Diff line change
Expand Up @@ -201,16 +201,16 @@ do
--target)
TARGETDIR="$2"
KEEP=y
shift 2
if ! shift 2; then MS_Help; exit 1; fi
;;
--header)
HEADER="$2"
shift 2
if ! shift 2; then MS_Help; exit 1; fi
;;
--license)
LICENSE=`cat $2`
shift 2
;;
LICENSE=`cat $2`
if ! shift 2; then MS_Help; exit 1; fi
;;
--follow)
TAR_ARGS=cvfh
DU_ARGS=-ksL
Expand Down Expand Up @@ -241,7 +241,7 @@ do
;;
--lsm)
LSM_CMD="cat \"$2\" >> \"\$archname\""
shift 2
if ! shift 2; then MS_Help; exit 1; fi
;;
-q | --quiet)
QUIET=y
Expand Down

0 comments on commit 2c60998

Please sign in to comment.