From c372f57a0a887b47c094c330501b946ee19b0547 Mon Sep 17 00:00:00 2001 From: Shatadru Bandyopadhyay Date: Wed, 4 Jun 2025 01:34:30 +0100 Subject: [PATCH] Fix tempdirname generation command --- otpgen/otpgen.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/otpgen/otpgen.sh b/otpgen/otpgen.sh index c05421e..32dc5f6 100755 --- a/otpgen/otpgen.sh +++ b/otpgen/otpgen.sh @@ -53,8 +53,8 @@ debug_var="" debug=2 tempdirname=$(mktemp -d) if [ -z "$tempdirname" ]; then - # This can slow down the script - tempdirname=$(timeout 2 < /dev/urandom tr -dc 'a-zA-Z0-9' | fold -w 10 | head -n 1) + # This can slow down the script + tempdirname=$(timeout 2 tr -dc 'a-zA-Z0-9' < /dev/urandom | fold -w 10 | head -n 1) fi if [ -z "$tempdirname" ]; then