hush: remove extra comparison from prev commit
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
diff --git a/shell/hush.c b/shell/hush.c
index 0333395..945077d 100644
--- a/shell/hush.c
+++ b/shell/hush.c
@@ -2647,14 +2647,12 @@
end = --exp_word;
if (*exp_word != ':') /* not ${var::...} */
beg = bb_strtou(exp_word, &end, 0);
- //bb_error_msg("beg:'%s'=%u end:'%s'", exp_word, beg, end);
+ //bb_error_msg("beg:'%s'=%u end:'%s'", exp_word, beg, end);
if (*end == ':') {
len = bb_strtou(end + 1, &end, 0);
//bb_error_msg("len:%u end:'%s'", len, end);
}
- if (*end == '\0'
- && end != exp_word /* not "${var:}" */
- ) {
+ if (*end == '\0') {
//bb_error_msg("from val:'%s'", val);
if (!val || beg >= strlen(val))
val = "";