diff options
Diffstat (limited to 'libbb')
-rw-r--r-- | libbb/compare_string_array.c | 10 | ||||
-rw-r--r-- | libbb/lineedit.c | 2 | ||||
-rw-r--r-- | libbb/xfuncs.c | 2 |
3 files changed, 7 insertions, 7 deletions
diff --git a/libbb/compare_string_array.c b/libbb/compare_string_array.c index 7b5ce856d..151b50817 100644 --- a/libbb/compare_string_array.c +++ b/libbb/compare_string_array.c @@ -70,9 +70,9 @@ int index_in_substrings(const char *strings, const char *key) const char *nth_string(const char *strings, int n) { - while (n) { - n--; - strings += strlen(strings) + 1; - } - return strings; + while (n) { + n--; + strings += strlen(strings) + 1; + } + return strings; } diff --git a/libbb/lineedit.c b/libbb/lineedit.c index 69768da30..3ccddbcbf 100644 --- a/libbb/lineedit.c +++ b/libbb/lineedit.c @@ -65,7 +65,7 @@ enum { /* We use int16_t for positions, need to limit line len */ MAX_LINELEN = CONFIG_FEATURE_EDITING_MAX_LEN < 0x7ff0 - ? CONFIG_FEATURE_EDITING_MAX_LEN + ? CONFIG_FEATURE_EDITING_MAX_LEN : 0x7ff0 }; diff --git a/libbb/xfuncs.c b/libbb/xfuncs.c index 6d50bf9bc..25c36bd07 100644 --- a/libbb/xfuncs.c +++ b/libbb/xfuncs.c @@ -166,7 +166,7 @@ int ndelay_on(int fd) int close_on_exec_on(int fd) { - return fcntl(fd, F_SETFD, FD_CLOEXEC); + return fcntl(fd, F_SETFD, FD_CLOEXEC); } int ndelay_off(int fd) |