KSaveFile, QSaveFile, QFile

Christoph Cullmann cullmann at absint.com
Sun Mar 24 15:25:20 GMT 2013


> On Thursday 21 March 2013 19:02:13 David Faure wrote:
> > I'm afraid it's one or the other:
> > * safe code, always a working file available, but hardlinks get
> > splitted up
> > * possibility to corrupt the existing file, but a backup exists;
> > hardlinks
> > are  kept.
> 
> OK, bug number 2, saving into a non-writable directory, also leads to
> the
> above issue: no way to use the "safe code".
> 
> So I implemented direct-overwrite for the case of a non-writable
> directory.
> https://codereview.qt-project.org/52059
> If this is approved, then the same solution could be used to preserve
> hardlinks.... and to preserve the owner if different from the current
> user, for
> bug number 3.
> 
> In bug number 2 there was a suggestion of "finding another writable
> directory
> in the same partition and moving the file from there", but it seems
> rather
> difficult to find such a directory in general, and it wouldn't help
> with bugs 1
> and 3 anyway.
Hi,

sounds reasonable solutions for the current problems!
Searching for some directory that is writable is anyway problematic,
guess users will have to live with "less safe" saving in such settings.

Will KSaveFile get some of that patches, too?

Greetings
Christoph

-- 
----------------------------- Dr.-Ing. Christoph Cullmann ---------
AbsInt Angewandte Informatik GmbH      Email: cullmann at AbsInt.com
Science Park 1                         Tel:   +49-681-38360-22
66123 Saarbrücken                      Fax:   +49-681-38360-20
GERMANY                                WWW:   http://www.AbsInt.com
--------------------------------------------------------------------
Geschäftsführung: Dr.-Ing. Christian Ferdinand
Eingetragen im Handelsregister des Amtsgerichts Saarbrücken, HRB 11234




More information about the kde-core-devel mailing list