tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: core statement on fexecve, O_EXEC, and O_SEARCH



On Mon, Nov 26, 2012 at 01:49:09AM +0300, Alan Barrett wrote:
> 
> If necessary, the open(2) syscall could be versioned so that 
> O_RDONLY is no longer defined as zero.

Actually we could redefine (say)
        O_RDONLY        0x10000
        O_WRONLY        0x20000
        O_RDWR          (O_RDONLY | O_WRONLY)
        O_SEARCH        0x40000
        O_EXEC          0x80000
(or similar)
and fallback on the value in bits 0 and 1 if none of the above are set.

That doesn't require a syscall version bump.

        David

-- 
David Laight: david%l8s.co.uk@localhost


Home | Main Index | Thread Index | Old Index