@@ -75,7 +75,7 @@ module_param(uid, int, 0644);
7575 * Another reason for this is that we can not get sys_open.
7676 * It is a static variable, so it is not exported.
7777 */
78- static asmlinkage int (* original_call )(const char * , int , int );
78+ static asmlinkage int (* original_call )(const char __user * , int , umode_t );
7979
8080/* The function we will replace sys_open (the function called when you
8181 * call the open system call) with. To find the exact prototype, with
@@ -87,7 +87,8 @@ static asmlinkage int (*original_call)(const char *, int, int);
8787 * wreck havoc and require programs to be recompiled, since the system
8888 * calls are the interface between the kernel and the processes).
8989 */
90- static asmlinkage int our_sys_open (const char * filename , int flags , int mode )
90+ static asmlinkage int our_sys_open (const char __user * filename , int flags ,
91+ umode_t mode )
9192{
9293 int i = 0 ;
9394 char ch ;
@@ -107,7 +108,7 @@ static asmlinkage int our_sys_open(const char *filename, int flags, int mode)
107108 return original_call (filename , flags , mode );
108109}
109110
110- static unsigned long * * aquire_sys_call_table (void )
111+ static unsigned long * * acquire_sys_call_table (void )
111112{
112113#ifdef HAVE_KSYS_CLOSE
113114 unsigned long int offset = PAGE_OFFSET ;
@@ -185,7 +186,7 @@ static void disable_write_protection(void)
185186
186187static int __init syscall_start (void )
187188{
188- if (!(sys_call_table = aquire_sys_call_table ()))
189+ if (!(sys_call_table = acquire_sys_call_table ()))
189190 return -1 ;
190191
191192 disable_write_protection ();
0 commit comments