blob: bcdd95d8c4b68f485e6212f20f6433e5410ee56e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
inspired by upstream fix in commit ff03702fdebb6c6c55532a6768b404706823c339
https://gitlab.com/apparmor/apparmor/-/commit/ff03702fdebb6c6c55532a6768b404706823c339
diff --git a/parser/rule.h b/parser/rule.h
index 05dbed1..e041f31 100644
--- a/rule.h
+++ b/rule.h
@@ -208,13 +208,13 @@ public:
}
int cmp(prefixes const &rhs) const {
- if ((uint) audit < (uint) rhs.audit)
+ if ((unsigned int) audit < (unsigned int) rhs.audit)
return -1;
- if ((uint) audit > (uint) rhs.audit)
+ if ((unsigned int) audit > (unsigned int) rhs.audit)
return 1;
- if ((uint) rule_mode < (uint) rhs.rule_mode)
+ if ((unsigned int) rule_mode < (unsigned int) rhs.rule_mode)
return -1;
- if ((uint) rule_mode > (uint) rhs.rule_mode)
+ if ((unsigned int) rule_mode > (unsigned int) rhs.rule_mode)
return 1;
if (owner < rhs.owner)
return -1;
@@ -224,9 +224,9 @@ public:
}
bool operator<(prefixes const &rhs) const {
- if ((uint) audit < (uint) rhs.audit)
+ if ((unsigned int) audit < (unsigned int) rhs.audit)
return true;
- if ((uint) rule_mode < (uint) rhs.rule_mode)
+ if ((unsigned int) rule_mode < (unsigned int) rhs.rule_mode)
return true;
if (owner < rhs.owner)
return true;
|