~mariusko/urfkill/master

« back to all changes in this revision

Viewing changes to src/urf-arbitrator.c

  • Committer: GitHub
  • Author(s): Gary Ching-Pang Lin
  • Date: 2021-04-01 08:04:29 UTC
  • mfrom: (533.1.1)
  • Revision ID: git-v1:333a29d5d7b09c4ae296ec37d9c6aaaf1b8f539b
Merge pull request #14 from GlenPickle/master

Change size check to only fail if less than RFKILL_EVENT_SIZE_V1 as n…

Show diffs side-by-side

added added

removed removed

Lines of Context:
587
587
                        break;
588
588
                }
589
589
 
590
 
                if (len != RFKILL_EVENT_SIZE_V1) {
 
590
                /* There has been a change in the kernel that allows for an extra
 
591
                 * byte in the rfkill event struct that tracks a reason field.
 
592
                 * see commit id 14486c82612a177cb910980c70ba900827ca0894 for
 
593
                 * more information
 
594
                 */
 
595
                if (len < RFKILL_EVENT_SIZE_V1) {
591
596
                        g_warning("Wrong size of RFKILL event\n");
592
597
                        continue;
593
598
                }