summaryrefslogtreecommitdiffstats
path: root/src/rand.sh
diff options
context:
space:
mode:
authorPatrick McDermott <patrick.mcdermott@libiquity.com>2019-04-19 21:26:04 (EDT)
committer Patrick McDermott <patrick.mcdermott@libiquity.com>2019-04-19 21:26:04 (EDT)
commit44e452fb3c8cc7a093d72fbc280be3973e627a62 (patch)
treedc169666d13834de17d3c984317e29ec4af1d04f /src/rand.sh
parentc752393c58c37dc7e8403b8b87d0943c1fe8c8b9 (diff)
Add braces to param exps in arith substs
Diffstat (limited to 'src/rand.sh')
-rw-r--r--src/rand.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rand.sh b/src/rand.sh
index 872d3fb..f2b3cd4 100644
--- a/src/rand.sh
+++ b/src/rand.sh
@@ -37,6 +37,6 @@ srand()
rand()
{
# Increment, multiplier, and modulus values are those used in glibc.
- rand_x=$((1103515245 * $rand_x + 12345))
- rand_x=$(($rand_x % 4294967296))
+ rand_x=$((1103515245 * ${rand_x} + 12345))
+ rand_x=$((${rand_x} % 4294967296))
}