Re: Surviving /dev/null disappearance

From: Jeremie Le Hen <jeremie_at_le-hen.org>
Date: Thu, 5 Apr 2007 22:35:04 +0200
Hi, Maxim, Andrew, Chuck,

On Wed, Apr 04, 2007 at 04:28:38PM -0700, Maxim Sobolev wrote:
> >>Isn't there some safety-net wrapper function that
> >>refuses to remove device nodes and maybe some other
> >>types of files?
> >
> >Why not set a filesystem flag like schg on device nodes under a devfs 
> >tree...?
> 
> Well, I suspect that it may cause ld(1) fail instead. What we want it to 
> do is to not perform unlink(2) before open(2) when -o argument is device 
> node.

Do you have any idea why ld(1) doesn't merely use open(2) with
O_TRUNC, instead of unlinking the file ?

Regards,
-- 
Jeremie Le Hen
< jeremie at le-hen dot org >< ttz at chchile dot org >
Received on Thu Apr 05 2007 - 19:05:39 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:07 UTC