bug-coreutils
[Top][All Lists]
Advanced

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

Patch against src/remove.c for correct handling of negative error codes


From: Axel Dörfler
Subject: Patch against src/remove.c for correct handling of negative error codes
Date: Sat, 29 Mar 2008 18:49:02 +0100

Hi,

the enclosed patch changes the following (remove.c against HEAD):

* write_protected_non_symlink() now returns -1 for error (errno will be
set accordingly), 0 for everything fine, and 1 if it's a write
protected file.
* prompt() now deals with the changed semantics of the above function.

It's needed because error codes are expressed with negative values on
some platforms like Haiku, and BeOS; previously, the code incorrectly
assumed error codes would always be positive.

Kind Regards,
   Axel Dörfler.

Attachment: remove.c.diff
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]