To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=100542
                 Issue #|100542
                 Summary|Failure to save due to over quota causes file to me un
                        |link()ed
               Component|framework
                 Version|OOo 3.0.1
                Platform|Unknown
                     URL|
              OS/Version|All
                  Status|UNCONFIRMED
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|code
             Assigned to|tm
             Reported by|abo





------- Additional comments from a...@openoffice.org Wed Mar 25 12:08:48 +0000 
2009 -------
Steps to reproduce:

1. Open a document.
2. Edit it.
3. Fill the file system or quota so that no new files can be created.
4. Ctrl-S

Expected behaviour:
An error dialog.

Actual behaviour:
The original file is unlink()ed.
An error dialog.

Details:
strace shows that it tries to write two files "example0.odt" and "example.odt"
in the $profile/user/backup/ directory, and then tries to write "example0.odt"
in the same directory as "example.odt". All three open(O_CREAT) calls fails.

After that it stats and unlinks "example.odt". It actually does not try to
create a new file after unlinking the original file.

Expected behaviour 1: Only unlink a file when it is certain that it will at
least try to write a new file.

Expected behaviour 2: Give up trying to replace a file if no backup files could
be created first, and give up _before_ the unlink().

I've reproduced this with a home directory in an ext3 filesystem which is out of
inodes (open() => ENOSPC) and also with a home directory in AFS with full quota
(open() => EDQUOT).

I also tried this with a home directory in a filesystem where there are free
inodes but no free blocks. In that case the open(O_CREAT) succeeds but write()
fails when creating the backup files. When that happens, the original file is
left intact. So in that case the error is dealt with in a meaningful way.

This is with openoffice.org-writer-3.0.1-15.3.fc10.x86_64 (Fedora 10). I've also
seen the same behaviour in StarSuite 8 on Sparc/Solaris so I doubt it's an issue
specific to the Fedora build. (I'm willing to file a bug report at the distro
level and/or try to reproduce with a vanilla build if required.)

---------------------------------------------------------------------
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@framework.openoffice.org
For additional commands, e-mail: issues-h...@framework.openoffice.org


---------------------------------------------------------------------
To unsubscribe, e-mail: allbugs-unsubscr...@openoffice.org
For additional commands, e-mail: allbugs-h...@openoffice.org

Reply via email to