X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=fs%2Fexec.c;h=4a790f2e224ef260d1ca77f6d187f4199c14aefe;hb=bd39597cbd42a784105a04010100e27267481c67;hp=32993beecbe91a10670cc4f5a9a72a5faf813c56;hpb=f3efbe582b5396d134024c03a5fa253f2a85d9a6;p=linux-2.6-omap-h63xx.git diff --git a/fs/exec.c b/fs/exec.c index 32993beecbe..4a790f2e224 100644 --- a/fs/exec.c +++ b/fs/exec.c @@ -391,7 +391,7 @@ static int count(char __user * __user * argv, int max) if (!p) break; argv++; - if(++i > max) + if (i++ >= max) return -E2BIG; cond_resched(); } @@ -752,11 +752,11 @@ static int exec_mmap(struct mm_struct *mm) tsk->active_mm = mm; activate_mm(active_mm, mm); task_unlock(tsk); - mm_update_next_owner(old_mm); arch_pick_mmap_layout(mm); if (old_mm) { up_read(&old_mm->mmap_sem); BUG_ON(active_mm != old_mm); + mm_update_next_owner(old_mm); mmput(old_mm); return 0; } @@ -1189,7 +1189,7 @@ int search_binary_handler(struct linux_binprm *bprm,struct pt_regs *regs) return retval; /* Remember if the application is TASO. */ - bprm->sh_bang = eh->ah.entry < 0x100000000UL; + bprm->taso = eh->ah.entry < 0x100000000UL; bprm->file = file; bprm->loader = loader;