From d5dc9c8f459acc56d21d288c9270f1038c25c2df Mon Sep 17 00:00:00 2001 From: Dylan Araps Date: Mon, 25 Feb 2019 08:24:50 +0200 Subject: [PATCH] ensure that -l is an int --- pash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pash b/pash index 4071cfe..7af630a 100755 --- a/pash +++ b/pash @@ -115,7 +115,7 @@ get_args() { while getopts ":ncvql:" opt; do case $opt in n) plain=1 ;; - l) length=$((OPTARG>300?300:OPTARG)) ;; + l) length=${OPTARG//[^0-9]} ;; c) clipboard=1 ;; q) quiet=1 ;; v) printf '%s\n' "pash 0.01"; exit ;;