summaryrefslogtreecommitdiff
path: root/shell
diff options
context:
space:
mode:
authorDenys Vlasenko2023-06-18 19:30:22 +0200
committerDenys Vlasenko2023-06-18 19:30:22 +0200
commit10cce8ae35654585a09d6e839dd502f04b81599d (patch)
treedf0692147819bad41afb5b825a4ce9775590d2a0 /shell
parent7701b526a720c4a84839174fe6b084d831ac90c9 (diff)
downloadbusybox-10cce8ae35654585a09d6e839dd502f04b81599d.zip
busybox-10cce8ae35654585a09d6e839dd502f04b81599d.tar.gz
shell/math: explain why we use separate &end
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'shell')
-rw-r--r--shell/math.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/shell/math.c b/shell/math.c
index 6784eee..0b30e08 100644
--- a/shell/math.c
+++ b/shell/math.c
@@ -706,7 +706,7 @@ evaluate_string(arith_state_t *math_state, const char *expr)
char *end;
numstackptr->var_name = NULL;
errno = 0;
- end = (char*) expr; /* separate variable to go on stack */
+ /* code is smaller compared to using &expr here: */
numstackptr->val = strto_arith_t(expr, &end);
expr = end;
dbg("[%d] val:%lld", (int)(numstackptr - numstack), numstackptr->val);