From 83b0f0b3a05323dfb906ecf915f979d01bc2f2c3 Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Thu, 25 Apr 2019 22:15:10 -0400 Subject: srand(): Shift argument and catch null string --- (limited to 'src') diff --git a/src/rand.sh b/src/rand.sh index 8592dd6..9b2e716 100644 --- a/src/rand.sh +++ b/src/rand.sh @@ -23,9 +23,10 @@ rand_x=1 srand() { local x="${1}" + shift 1 case "${x}" in - *[!0-9]*) + *[!0-9]* | '') warn "$(get_msg 'rand_bad_x')" return 1 ;; -- cgit v0.9.1