tech-userlevel archive

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

Re: [PATCH] Re: iflag/oflag for dd(1)



On Tue, Mar 17, 2015 at 11:40:08AM -0400, Christos Zoulas wrote:
> O_CREAT:
> 	It is already in the oflag, there is no way to clear it.

The code I wrote haa s oflag overrinding the default O_CREAT. Is that
wrong?

> O_RDWR:
> 	It is already in the oflag, there is no way to clear it.
> 	It does not make a lot of sense for the iflag

Except if you have some fancy filesystem that behaves differently 
when file are open R/W.
> 
> O_TRUNC:
> 	For oflag it will lead to confusion with conv=notrunc and no way
> 	to clear it. Two ways to do the same thing.

I noted it in the man page: O_TRUNC is added unless you have oseek, seek
or notrunc. 

> O_APPEND:
> 	This is useful for oflag I guess, not for iflag...

You suggest it should be filtered out only for iflag?

-- 
Emmanuel Dreyfus
manu%netbsd.org@localhost


Home | Main Index | Thread Index | Old Index