lkml.org 
[lkml]   [1996]   [Nov]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectUpdated sysctl patch for 2.1.13

Hi,

I updated my sysctl patch for linux 2.1.13, it's basically the same as the
previous on except for the euid/egid fix that is already in the kernel.
Cheers,
Farzad


diff -ur linux.orig/drivers/char/softdog.c linux/drivers/char/softdog.c
--- linux.orig/drivers/char/softdog.c Sun Nov 24 22:15:42 1996
+++ linux/drivers/char/softdog.c Sun Nov 24 22:17:13 1996
@@ -93,7 +93,7 @@
#endif
}

-static int softdog_write(struct inode *inode, struct file *file, const char *data, int len)
+static long softdog_write(struct inode *inode, struct file *file, const char *data, unsigned long len)
{
/*
* Refresh the timer.
diff -ur linux.orig/fs/binfmt_java.c linux/fs/binfmt_java.c
--- linux.orig/fs/binfmt_java.c Sun Nov 24 22:16:02 1996
+++ linux/fs/binfmt_java.c Sun Nov 24 22:25:37 1996
@@ -13,6 +13,7 @@
#include <linux/stat.h>
#include <linux/malloc.h>
#include <linux/binfmts.h>
+#include <linux/sysctl.h>

#define _PATH_JAVA "/usr/bin/java"
#define _PATH_APPLET "/usr/bin/appletviewer"
@@ -22,6 +23,19 @@
char binfmt_java_interpreter[65] = _PATH_JAVA;
char binfmt_java_appletviewer[65] = _PATH_APPLET;

+static struct ctl_table_header *java_sysctl_header;
+static struct ctl_table java_table[] = {
+ {KERN_JAVA_INTERPRETER, "java-interpreter", binfmt_java_interpreter,
+ 64, 0644, NULL, &proc_dostring, &sysctl_string },
+ {KERN_JAVA_APPLETVIEWER, "java-appletviewer", binfmt_java_appletviewer,
+ 64, 0644, NULL, &proc_dostring, &sysctl_string },
+ {0}
+};
+static struct ctl_table java_root_table[] = {
+ {CTL_KERN, "kernel", NULL, 0, 0555, java_table},
+ {0}
+};
+
static int do_load_java(struct linux_binprm *bprm,struct pt_regs *regs)
{
char *i_name;
@@ -166,6 +180,7 @@
};

int init_java_binfmt(void) {
+ java_sysctl_header = register_sysctl_table(java_root_table, 0);
register_binfmt(&java_format);
return register_binfmt(&applet_format);
}
@@ -179,5 +194,6 @@
void cleanup_module( void) {
unregister_binfmt(&java_format);
unregister_binfmt(&applet_format);
+ unregister_sysctl_table(java_sysctl_header);
}
#endif
diff -ur linux.orig/kernel/sysctl.c linux/kernel/sysctl.c
--- linux.orig/kernel/sysctl.c Sun Nov 24 22:16:20 1996
+++ linux/kernel/sysctl.c Sun Nov 24 22:21:23 1996
@@ -99,8 +99,6 @@
static int do_securelevel_strategy (ctl_table *, int *, int, void *, size_t *,
void *, size_t, void **);

-extern char binfmt_java_interpreter[], binfmt_java_appletviewer[];
-
/* The default sysctl tables: */

static ctl_table root_table[] = {
@@ -140,14 +138,8 @@
#ifdef CONFIG_ROOT_NFS
{KERN_NFSRNAME, "nfs-root-name", nfs_root_name, NFS_ROOT_NAME_LEN,
0644, NULL, &proc_dostring, &sysctl_string },
- {KERN_NFSRNAME, "nfs-root-addrs", nfs_root_addrs, NFS_ROOT_ADDRS_LEN,
+ {KERN_NFSRADDRS, "nfs-root-addrs", nfs_root_addrs, NFS_ROOT_ADDRS_LEN,
0644, NULL, &proc_dostring, &sysctl_string },
-#endif
-#ifdef CONFIG_BINFMT_JAVA
- {KERN_JAVA_INTERPRETER, "java-interpreter", binfmt_java_interpreter,
- 64, 0644, NULL, &proc_dostring, &sysctl_string },
- {KERN_JAVA_APPLETVIEWER, "java-appletviewer", binfmt_java_appletviewer,
- 64, 0644, NULL, &proc_dostring, &sysctl_string },
#endif
{0}
};

--
Farzad FARID
Administrateur Reseau
SGIP - Publicis




\
 
 \ /
  Last update: 2005-03-22 13:37    [W:0.033 / U:3.140 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site