aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/event_analyzing_sample.py
diff options
context:
space:
mode:
authorRebecca Mckeever <[email protected]>2022-04-16 05:24:34 -0500
committerGreg Kroah-Hartman <[email protected]>2022-04-20 18:45:50 +0200
commitbb5369edbab8363a8a9a0c9ba59cb85020accb68 (patch)
tree5657a2d7b84fb8e5865059d3af6f189f879d9f41 /tools/perf/scripts/python/event_analyzing_sample.py
parenta8d412ec986b95f146c6786c76bb471e1b602589 (diff)
staging: rtl8192u: compare strcmp result to zero
Add " == 0" to the condition in both else if branches to address a possible bug. strcmp returns 0 when its arguments are equal, which evaluates to false, often leading to errors when used in if statements. Currently, the statement in the first else if branch does not execute when its arguments are equal, but it does execute when crypt->ops->name equals any string other than "WEP" or "TKIP". Similarly, the second else if branch does not execute when its arguments are equal, and it only executes when crypt->ops->name equals "TKIP". The else branch never executes. It is unlikely that this is working as intended. Reviewed-by: Dan Carpenter <[email protected]> Signed-off-by: Rebecca Mckeever <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/event_analyzing_sample.py')
0 files changed, 0 insertions, 0 deletions