Description of problem: Blender is unable to save over an existing /tmp/quit.blend Version-Release number of selected component (if applicable): blender-2.49b-1.fc12.x86_64 How reproducible: 100% Steps to Reproduce: 1. Start blender with no /tmp/quit.blend file 2. Do some change, e.g x then enter (to delete the cube) 3. Quit 4. Repeat the above with the /tmp/quit.blend file Actual results: Quitting on the second run results in error dialogue say it can't save to /tmp/quit.blend, check you have permissions. Expected results: Save to /tmp/quit.blend and don't give any error. Additional info: This seems to be due to blender opening the file as 21265 open("/tmp/quit.blend", O_WRONLY|O_CREAT|O_EXCL|O_TRUNC, 0666) = -1 EEXIST (File exists) The combination of O_CREAT and O_EXCL on an already existing file is an error. I'm guessing this is from some patch applied to the Fedora Blender package as Blender 2.49b from upstream doesn't have this problem. 29128 open("/tmp/quit.blend", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 5 Cheers, Andrew
This change was make to fix BZ #444535 where a rece condition was reported. It may be nice if you can tell me, which file permission the /tmp/quit.blend file has on your system after you have finished blender. From my point of view O_EXCL means, that nobody may open the file during the time where the file is opened. but after the end of the application the file shound be accessable.
I was just reading the man page. O_EXCL Ensure that this call creates the file: if this flag is speci- fied in conjunction with O_CREAT, and pathname already exists, then open() will fail. Hopefully the following helps. $ umask 0007 $ ls -l /tmp/quit.blend ls: cannot access /tmp/quit.blend: No such file or directory $ blender (make some change, quit) $ ls -l /tmp/quit.blend -rw-rw---- 1 andrew andrew 54884 Jan 12 16:58 /tmp/quit.blend $ blender (make some change quit) Get the error message. This is due (according to the man page) to O_EXCL|O_CREAT being used an existing file.
Oh yeah, forgot to mention that blender is actually segfaulting at this point. $ blender Compiled with Python version 2.6.2. Checking for installed Python... got it! mywinset 29555: doesn't exist /usr/bin/blender: line 92: 35589 Segmentation fault /usr/bin/${blend}.bin $@ and in dmesg blender.bin[35589] general protection ip:554a38 sp:7fff0a79a4c8 error:0 in blender.bin[400000+b98000] If you don't have an existing /tmp/quit.blend you get a clean exit $ blender Compiled with Python version 2.6.2. Checking for installed Python... got it! Saved session recovery to /tmp/quit.blend Blender quit
Maybe it needs to be a bit more more clever and check for the existence of the file first, it if exists and is a regular file owned by the user running blender then do something like save the quit.blend as something like (random file name) quit.blend-tmpxdsa13 and then do a rename over quit.blend. If there's a quit.blend owned by another user, then I don't know.
It may be nice, if you can try out blender-2.49b-5.fc13, which should be available in rawhide in the next days.
blender-2.49b-5.fc12 has been submitted as an update for Fedora 12. http://admin.fedoraproject.org/updates/blender-2.49b-5.fc12
blender-2.49b-5.fc12 has been pushed to the Fedora 12 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with su -c 'yum --enablerepo=updates-testing update blender'. You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F12/FEDORA-2010-0753
Yes, that update seems to have fixed the issue. Cheers, Andrew
blender-2.49b-5.fc12 has been pushed to the Fedora 12 stable repository. If problems still persist, please make note of it in this bug report.