Public bug reported:
We are working on a tool for protecting user data. We have observed that
Texmaker saves a file simply by a overwrite. (texmaker.cpp:3300-3315)
After the file is truncated to zero byte, if the system crashes, or the
disk runs out of space, the contents in the file is permanently gone -
Texmaker seems not to backing up the file.
A safe way is to write contents to a backup, and call fdatasync() to
ensure persistency, and then overwrite the file. It hurts a little bit
of performance, but avoids the problem.
It can also be resolved by QSaveFile, but it seems not available in Qt4.
Thank you for your attention.
** Affects: texmaker (Ubuntu)
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1553361
Title:
File save safety
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/texmaker/+bug/1553361/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs