Jan Engelhardt
ddb300396c
OBS-URL: https://build.opensuse.org/package/show/security:netfilter/iproute2?expand=0&rev=124
31 lines
751 B
Diff
31 lines
751 B
Diff
---
|
|
lib/utils.c | 8 ++++++--
|
|
1 file changed, 6 insertions(+), 2 deletions(-)
|
|
|
|
Index: iproute2-4.8.0/lib/utils.c
|
|
===================================================================
|
|
--- iproute2-4.8.0.orig/lib/utils.c
|
|
+++ iproute2-4.8.0/lib/utils.c
|
|
@@ -49,6 +49,10 @@ int get_hex(char c)
|
|
return -1;
|
|
}
|
|
|
|
+#ifndef HZ
|
|
+#define HZ sysconf(_SC_CLK_TCK)
|
|
+#endif
|
|
+
|
|
int get_integer(int *val, const char *arg, int base)
|
|
{
|
|
long res;
|
|
@@ -683,8 +687,8 @@ int matches(const char *cmd, const char
|
|
|
|
int inet_addr_match(const inet_prefix *a, const inet_prefix *b, int bits)
|
|
{
|
|
- const __u32 *a1 = a->data;
|
|
- const __u32 *a2 = b->data;
|
|
+ const __u32 *a1 = (__u32*)a->data;
|
|
+ const __u32 *a2 = (__u32*)b->data;
|
|
int words = bits >> 0x05;
|
|
|
|
bits &= 0x1f;
|