Bastian Blank <[EMAIL PROTECTED]> writes: > severity 380531 normal > thanks > > On Sun, Jul 30, 2006 at 07:39:39PM +0100, Roger Leigh wrote: >> personality(2) only works the first time it is called [in the lifetime >> of a process/program]. All subsequent calls return EPERM, which is >> not a documented return value; > > As the linux source don't document return values and it is linux > specific, the linux kernel is allowed to return any error is thinks is > needed.
The point was, it's not documented *in the kernel source*, either. -EPERM is not used *anywhere*, in either the arch/mips or generic kernel execdomain code. See kernel/exec_domain.c and arch/mips/kernel/linux32.c. >> None of the other architectures I have tested >> (amd64, arm, i386, ia64, powerpc) behave this way: personality(2) is >> not a privileged call. > > That it return sane values everything else don't document it as a non > priviledged call. There are no permissions checks in the kernel source. EPERM is a bogus return value due to some weirdness in the sys32_personality code on mips (See ths's patch). -- .''`. Roger Leigh : :' : Debian GNU/Linux http://people.debian.org/~rleigh/ `. `' Printing on GNU/Linux? http://gutenprint.sourceforge.net/ `- GPG Public Key: 0x25BFB848 Please sign and encrypt your mail.
pgpL3DO0Ou94v.pgp
Description: PGP signature