~libv4l/libv4l/dev

Viewing all changes in revision 4715.

  • Committer: Hans Verkuil
  • Date: 2021-06-12 09:43:20 UTC
  • Revision ID: git-v1:26f9554fb9d2560ffc9a45199b5e847c3bb0ac6f
cec-compliance/follower: fix type comparison warnings

This fixes the following warnings on a 32-bit system:

cec-test.cpp: In function ‘int deck_ctl_deck_ctl(node*, unsigned int, unsigned int, bool)’:
cec-test.cpp:742:69: warning: comparison of integer expressions of different signedness: ‘unsigned int’ and ‘time_t’ {aka ‘long int’} [-Wsign-compare]
  742 |  for (unsigned i = 0; deck_status == CEC_OP_DECK_INFO_SKIP_FWD && i < long_timeout; i++) {
      |                                                                   ~~^~~~~~~~~~~~~~
cec-test.cpp:754:69: warning: comparison of integer expressions of different signedness: ‘unsigned int’ and ‘time_t’ {aka ‘long int’} [-Wsign-compare]
  754 |  for (unsigned i = 0; deck_status == CEC_OP_DECK_INFO_SKIP_REV && i < long_timeout; i++) {
      |                                                                   ~~^~~~~~~~~~~~~~

cec-processing.cpp: In function ‘void testProcessing(node*, bool)’:
cec-processing.cpp:1105:47: warning: comparison of integer expressions of different signedness: ‘time_t’ {aka ‘long int’} and ‘unsigned int’ [-Wsign-compare]
 1105 |       (time(nullptr) - last_pwr_status_toggle > node->state.toggle_power_status)) {
      |        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: