Proposed new Unix POSIX_OPEN/POSIX_UNLINK calls.

Jeremy Allison jra at samba.org
Wed Feb 7 00:54:48 GMT 2007


On Tue, Feb 06, 2007 at 04:26:03PM -0800, Jeremy Allison wrote:
> 
> MKDIR call :
> 
> To do the equivalent of a mkdir(path, mode) do the
> following request :
> 
> flags: 0
> open flags: SMB_O_DIRECTORY|SMB_O_CREAT
> mode_t: Requested mode_t for the new directory.
> 
> The reply data block looks like the following
> 
> Size              Offset                  Value
> -----------------------------------------------
> 1 byte           0                    oplock granted flags
>                                       (as returned by NTCreateX)
> 1 byte           1                    Must be Zero.
> 2 bytes          2                    Returned fnum.
> [2 - N bytes]    4                    Info level returned for the
>                                       opened file, or 0xFFFF if no
>                                       info level returned.

Quick clarification, for the mkdir call
varient of POSIX_OPEN the oplock granted
flags and returned fnum are undefined (usually zero).

For POSIX_OPEN and the mkdir varient the info
level returned field is actually two fields :

Size              Offset                  Value
-----------------------------------------------
2 bytes             4                    Info level retured (or 0xFFFF)
0 - N bytes         6                    Info level dependent data.

Jeremy.


More information about the samba-technical mailing list