]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - kernel/sys.c
mISDN: Fixed more indexing bugs
[linux-2.6-omap-h63xx.git] / kernel / sys.c
index d356d79e84ac5682553e76d1bb7f449e5f808e69..763c3c17ded3e6c818283da75dd0865b93858c7a 100644 (file)
@@ -33,6 +33,7 @@
 #include <linux/task_io_accounting_ops.h>
 #include <linux/seccomp.h>
 #include <linux/cpu.h>
+#include <linux/ptrace.h>
 
 #include <linux/compat.h>
 #include <linux/syscalls.h>
@@ -927,6 +928,7 @@ asmlinkage long sys_times(struct tms __user * tbuf)
                if (copy_to_user(tbuf, &tmp, sizeof(struct tms)))
                        return -EFAULT;
        }
+       force_successful_syscall_return();
        return (long) jiffies_64_to_clock_t(get_jiffies_64());
 }
 
@@ -1627,6 +1629,8 @@ static void k_getrusage(struct task_struct *p, int who, struct rusage *r)
        utime = stime = cputime_zero;
 
        if (who == RUSAGE_THREAD) {
+               utime = task_utime(current);
+               stime = task_stime(current);
                accumulate_thread_rusage(p, r);
                goto out;
        }