bug-coreutils
[Top][All Lists]
Advanced

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

bug#22769: In-place sorting of a file


From: Paul Eggert
Subject: bug#22769: In-place sorting of a file
Date: Mon, 22 Feb 2016 23:53:25 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1

Yanyan Jiang wrote:
If at this time, the system crashes (or later at write), the data is gone 
forever (or have a suffering recovery). Should we warn users of this, or add 
special treatment with this case (write a temp file and rename it)?

Thanks for reporting the issue. Writing to a temp file and renaming would have problems, as it might change the file's ownership or permissions or etc., and also won't behave as the user expects if the file has multiple hard links. We should at least warn users about the problem in the documentation, though, so I installed the attached patch on Savannah at:

http://git.savannah.gnu.org/cgit/coreutils.git/commit/?id=4c1995f1b673b0e1eae73a9db4e28016b86dee9e

Attachment: 0001-doc-document-sort-o-F-F-danger.txt
Description: Text document


reply via email to

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