diff options
author | J.R. Mauro <jrm8005@gmail.com> | 2009-01-05 23:08:53 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-01-06 22:52:42 +0100 |
commit | 9279bcc31698842961a30bb05b00aef7236dd728 (patch) | |
tree | e175b67a2928883d338f8cdf025aaa61fe991276 /drivers | |
parent | Staging: android: binder: Fix gcc warnings about improper format specifiers f... (diff) | |
download | linux-9279bcc31698842961a30bb05b00aef7236dd728.tar.xz linux-9279bcc31698842961a30bb05b00aef7236dd728.zip |
staging: android: binder: Fix use of euid
Task credentials were moved and must be accessed through task_struct.cred
Signed-off-by: J.R. Mauro <jrm8005@gmail.com>
Cc: Arve Hjønnevåg <arve@android.com>
Cc: Brian Swetland <swetland@google.com>
Cc: Robert Love <rlove@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/staging/android/binder.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/staging/android/binder.c b/drivers/staging/android/binder.c index 765048eaaf6d..7c3da5aa777a 100644 --- a/drivers/staging/android/binder.c +++ b/drivers/staging/android/binder.c @@ -1401,7 +1401,7 @@ binder_transaction(struct binder_proc *proc, struct binder_thread *thread, t->from = thread; else t->from = NULL; - t->sender_euid = proc->tsk->euid; + t->sender_euid = proc->tsk->cred->euid; t->to_proc = target_proc; t->to_thread = target_thread; t->code = tr->code; @@ -2593,16 +2593,16 @@ static long binder_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) goto err; } if (binder_context_mgr_uid != -1) { - if (binder_context_mgr_uid != current->euid) { + if (binder_context_mgr_uid != current->cred->euid) { printk(KERN_ERR "binder: BINDER_SET_" "CONTEXT_MGR bad uid %d != %d\n", - current->euid, + current->cred->euid, binder_context_mgr_uid); ret = -EPERM; goto err; } } else - binder_context_mgr_uid = current->euid; + binder_context_mgr_uid = current->cred->euid; binder_context_mgr_node = binder_new_node(proc, NULL, NULL); if (binder_context_mgr_node == NULL) { ret = -ENOMEM; |