syslogd/klogd-obsolete.patch

31 lines
772 B
Diff

Index: sysklogd-1.4.1/ksym_mod.c
===================================================================
--- sysklogd-1.4.1.orig/ksym_mod.c
+++ sysklogd-1.4.1/ksym_mod.c
@@ -89,6 +89,7 @@
#include <errno.h>
#include <sys/fcntl.h>
#include <sys/stat.h>
+#include <sys/syscall.h>
#include <stdarg.h>
#include <paths.h>
#include <limits.h>
@@ -105,7 +106,16 @@ struct kernel_sym
};
extern __off64_t lseek64 __P ((int __fd, __off64_t __offset, int __whence));
-extern int get_kernel_syms __P ((struct kernel_sym *__table));
+
+static int get_kernel_syms(struct kernel_sym *table)
+{
+#ifdef SYS_get_kernel_syms
+ return syscall(SYS_get_kernel_syms, table);
+#else
+ errno = ENOSYS;
+ return -1;
+#endif
+}
static inline __off64_t seek64(int fd, uintptr_t address)
{