|
@@ -57,6 +57,9 @@ static inline void syscall_get_arguments(struct task_struct *task,
|
|
|
unsigned int i, unsigned int n,
|
|
|
unsigned long *args)
|
|
|
{
|
|
|
+ if (n == 0)
|
|
|
+ return;
|
|
|
+
|
|
|
if (i + n > SYSCALL_MAX_ARGS) {
|
|
|
unsigned long *args_bad = args + SYSCALL_MAX_ARGS - i;
|
|
|
unsigned int n_bad = n + i - SYSCALL_MAX_ARGS;
|
|
@@ -81,6 +84,9 @@ static inline void syscall_set_arguments(struct task_struct *task,
|
|
|
unsigned int i, unsigned int n,
|
|
|
const unsigned long *args)
|
|
|
{
|
|
|
+ if (n == 0)
|
|
|
+ return;
|
|
|
+
|
|
|
if (i + n > SYSCALL_MAX_ARGS) {
|
|
|
pr_warning("%s called with max args %d, handling only %d\n",
|
|
|
__func__, i + n, SYSCALL_MAX_ARGS);
|