--- linux-2.2.10/arch/i386/mm/fault.c~ Sun Jul 18 15:58:11 1999 +++ linux-2.2.10/arch/i386/mm/fault.c Sun Jul 18 17:18:43 1999 @@ -287,8 +287,21 @@ up(&mm->mmap_sem); if (error_code & 4) { - printk("VM: killing process %s\n", tsk->comm); - do_exit(SIGKILL); + if (!((regs->eflags >> 12) & 3)) + { + printk("VM: killing process %s\n", tsk->comm); + do_exit(SIGKILL); + } + else + { + /* + * The task is running with privilegies and so we + * trust it and we give it a chance to die gracefully. + */ + printk("VM: terminating process %s\n", tsk->comm); + force_sig(SIGTERM, current); + return; + } } goto no_context;