[PATCH] setuid(2) buggy or bad docs

From: John Fremlin (vii@users.sourceforge.net)
Date: Tue Jun 19 2001 - 19:37:51 EST


setuid(2) differs from the OpenBSD setuid(2) in that -EPERM is
returned by the syscall even if the euid of the process matches the
uid passed to it.

Either I am non compos or the thing is very wrong. The docs
(man-pages-1.35) say

ERRORS
       EPERM The user is not the super-user, and uid does not
              match the effective or saved user ID of the calling
              process.

The following untested patch changes the kernel to match the
documentated behaviour.




-- 
Summer job urgently sought due to last minute visa trouble!
Please see http://ape.n3.net/cv.html

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Jun 23 2001 - 21:00:26 EST