From 947f659f969b318eb7757656e28188e5d2d0f5cf Mon Sep 17 00:00:00 2001 From: ridiculousfish Date: Fri, 19 Feb 2016 15:45:12 -0800 Subject: Miscellaneous cleanup and dead code removal Noticed by cppcheck --- src/builtin.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/builtin.cpp') diff --git a/src/builtin.cpp b/src/builtin.cpp index ae6c85b2..d79c8880 100644 --- a/src/builtin.cpp +++ b/src/builtin.cpp @@ -1705,7 +1705,6 @@ static unsigned int builtin_echo_digit(wchar_t wc, unsigned int base) static bool builtin_echo_parse_numeric_sequence(const wchar_t *str, size_t *consumed, unsigned char *out_val) { bool success = false; - unsigned char val = 0; //resulting character unsigned int start = 0; //the first character of the numeric part of the sequence unsigned int base = 0, max_digits = 0; @@ -1731,6 +1730,7 @@ static bool builtin_echo_parse_numeric_sequence(const wchar_t *str, size_t *cons if (base != 0) { unsigned int idx; + unsigned char val = 0; //resulting character for (idx = start; idx < start + max_digits; idx++) { unsigned int digit = builtin_echo_digit(str[idx], base); -- cgit v1.2.3