Fix a few incompatibility issues (#517)
* kernel: Use NR_syscalls instead of SECCOMP_ARCH_NATIVE_NR Old kernels don't has SECCOMP_ARCH_NATIVE_NR. But according to its definition, it's equal to NR_syscalls. So use NR_syscalls instead. * kernel: Fix wrong kernel version check fsnotify_add_inode_mark was introduced in 4.17-rc5, not 4.12
This commit is contained in:
@@ -66,7 +66,7 @@ static int add_mark_on_inode(struct inode *inode, u32 mask,
|
||||
if (!m)
|
||||
return -ENOMEM;
|
||||
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 17, 0)
|
||||
fsnotify_init_mark(m, g);
|
||||
m->mask = mask;
|
||||
ret = fsnotify_add_inode_mark(m, inode, 0);
|
||||
|
||||
Reference in New Issue
Block a user