diff options
Diffstat (limited to 'util-linux')
-rw-r--r-- | util-linux/getopt.c | 4 | ||||
-rw-r--r-- | util-linux/readprofile.c | 7 |
2 files changed, 6 insertions, 5 deletions
diff --git a/util-linux/getopt.c b/util-linux/getopt.c index 83cc1efea..f6ecc3dde 100644 --- a/util-linux/getopt.c +++ b/util-linux/getopt.c | |||
@@ -347,9 +347,9 @@ static struct option *add_long_options(struct option *long_options, char *option | |||
347 | 347 | ||
348 | static void set_shell(const char *new_shell) | 348 | static void set_shell(const char *new_shell) |
349 | { | 349 | { |
350 | if (!strcmp(new_shell, "bash") || !strcmp(new_shell, "sh")) | 350 | if (strcmp(new_shell, "bash") == 0 || strcmp(new_shell, "sh") == 0) |
351 | return; | 351 | return; |
352 | if (!strcmp(new_shell, "tcsh") || !strcmp(new_shell, "csh")) | 352 | if (strcmp(new_shell, "tcsh") == 0 || strcmp(new_shell, "csh") == 0) |
353 | option_mask32 |= SHELL_IS_TCSH; | 353 | option_mask32 |= SHELL_IS_TCSH; |
354 | else | 354 | else |
355 | bb_error_msg("unknown shell '%s', assuming bash", new_shell); | 355 | bb_error_msg("unknown shell '%s', assuming bash", new_shell); |
diff --git a/util-linux/readprofile.c b/util-linux/readprofile.c index d5230387c..31abb6bb2 100644 --- a/util-linux/readprofile.c +++ b/util-linux/readprofile.c | |||
@@ -174,7 +174,7 @@ int readprofile_main(int argc UNUSED_PARAM, char **argv) | |||
174 | bb_error_msg_and_die("%s(%i): wrong map line", | 174 | bb_error_msg_and_die("%s(%i): wrong map line", |
175 | mapFile, maplineno); | 175 | mapFile, maplineno); |
176 | 176 | ||
177 | if (!strcmp(fn_name, "_stext")) /* only elf works like this */ { | 177 | if (strcmp(fn_name, "_stext") == 0) /* only elf works like this */ { |
178 | add0 = fn_add; | 178 | add0 = fn_add; |
179 | break; | 179 | break; |
180 | } | 180 | } |
@@ -224,8 +224,9 @@ int readprofile_main(int argc UNUSED_PARAM, char **argv) | |||
224 | if (optBins) { | 224 | if (optBins) { |
225 | if (optVerbose || this > 0) | 225 | if (optVerbose || this > 0) |
226 | printf(" total\t\t\t\t%u\n", this); | 226 | printf(" total\t\t\t\t%u\n", this); |
227 | } else if ((this || optAll) | 227 | } else |
228 | && (fn_len = next_add-fn_add) != 0 | 228 | if ((this || optAll) |
229 | && (fn_len = next_add-fn_add) != 0 | ||
229 | ) { | 230 | ) { |
230 | if (optVerbose) | 231 | if (optVerbose) |
231 | printf("%016llx %-40s %6u %8.4f\n", fn_add, | 232 | printf("%016llx %-40s %6u %8.4f\n", fn_add, |