Wireshark-commits: [Wireshark-commits] master 47eb321: ui/gtk: fix weird check for axis orientation
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=47eb321c5d306c8561c13bba067f66e900ec5bb8
Submitter: Martin Mathieson (martin.r.mathieson@xxxxxxxxxxxxxx)
Changed: branch: master
Repository: wireshark
Commits:
47eb321 by Peter Wu (peter@xxxxxxxxxxxxx):
ui/gtk: fix weird check for axis orientation
There is only one meaning for the flags parameter, namely axis
orientation (x or y). Replace the bitmap by a bool instead.
Clang 3.7.0 reported this warning:
ui/gtk/tcp_graph.c:1652:29: warning: shifting a negative signed value is undefined [-Wshift-negative-value]
g->y_axis->flags &= ~AXIS_ORIENTATION;
~^~~~~~~~~~~~~~~~
ui/gtk/tcp_graph.c:140:28: note: expanded from macro 'AXIS_ORIENTATION'
#define AXIS_ORIENTATION 1 << 0
^
1 warning generated.
This (~1 << 0) happened to work because nothing is actually shifted.
Change-Id: I406235148b7826649d35647f5d0702cd72a925a5
Reviewed-on: https://code.wireshark.org/review/10658
Reviewed-by: Peter Wu <peter@xxxxxxxxxxxxx>
Petri-Dish: Peter Wu <peter@xxxxxxxxxxxxx>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@xxxxxxxxxxxxx>
Reviewed-by: Martin Mathieson <martin.r.mathieson@xxxxxxxxxxxxxx>
Actions performed:
from 6d10efc Qt: Add the Dissector Tables dialog.
adds 47eb321 ui/gtk: fix weird check for axis orientation
Summary of changes:
ui/gtk/rlc_lte_graph.c | 11 ++++-------
ui/gtk/tcp_graph.c | 11 ++++-------
2 files changed, 8 insertions(+), 14 deletions(-)