git.openpandora.org
/
pandora-kernel.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
x86/ptrace: Fix regs_get_argument_nth() to add correct offset
[pandora-kernel.git]
/
arch
/
x86
/
kernel
/
ptrace.c
diff --git
a/arch/x86/kernel/ptrace.c
b/arch/x86/kernel/ptrace.c
index
a33a17d
..
caffb68
100644
(file)
--- a/
arch/x86/kernel/ptrace.c
+++ b/
arch/x86/kernel/ptrace.c
@@
-150,7
+150,7
@@
static const int arg_offs_table[] = {
unsigned long regs_get_argument_nth(struct pt_regs *regs, unsigned int n)
{
if (n < ARRAY_SIZE(arg_offs_table))
unsigned long regs_get_argument_nth(struct pt_regs *regs, unsigned int n)
{
if (n < ARRAY_SIZE(arg_offs_table))
- return *(
(unsigned long
*)regs + arg_offs_table[n]);
+ return *(
unsigned long *)((char
*)regs + arg_offs_table[n]);
else {
/*
* The typical case: arg n is on the stack.
else {
/*
* The typical case: arg n is on the stack.