Dnia czwartek, 19 sierpnia 2021 23:32:44 CEST Paul Eggert pisze:
> On 8/19/21 1:43 PM, Krzysztof Żelechowski wrote:
> > The command { gzip b; } fails because it would compress [a] without
> > renaming it.
> > The command { gzip -k b; } would not compress [a], so there is no reason
> > to
> > fail.
>
> There is a safety reason to fail. A naive user might do this:
>
> gzip -k b && gzip -cd b.gz >b
>
> which would trash the hard-linked file as well.
That would replace the content of the file b with the content of the file b.
How bad can that be? ;-)
Chris