switched out 'head' for 'dd' in order to do chunking
This commit is contained in:
parent
d80f849f4a
commit
5094f35d05
1 changed files with 2 additions and 2 deletions
|
@ -48,13 +48,13 @@ fi
|
|||
## Split the key file into usable chunks that the QR encoder can consume
|
||||
chunks=()
|
||||
while true; do
|
||||
s=$( head -c ${max_qr_bytes} )
|
||||
s=$( dd bs=${max_qr_bytes} count=1 2>/dev/null )
|
||||
if [ ${#s} -gt 0 ]; then
|
||||
chunks+=("${s}")
|
||||
else
|
||||
break
|
||||
fi
|
||||
done <<< "$( cat ${asc_key} )"
|
||||
done < ${asc_key}
|
||||
|
||||
## For each chunk, encode it into a qr image
|
||||
index=1
|
||||
|
|
Loading…
Reference in a new issue