Description of problem:
We found the temporary file is left behind when the sed option '--copy' is used.
This problem happens when vdsm manipulate libvirt's configuration. Vdsm has to use the option '--copy' since the system call 'rename' is not allowed on bind-mount files (on ovirt node). I can't see the point of remaining the temporary file. My understanding is that with and without '--copy' should be just different ways(truncate+cp vs rename) to change the file in pace. So I think the temporary file should be removed after done.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
sed -i --copy -e 's/todo/done/' my_todo_list
then a temporary file like 'sedcMkUCu' was remained after the operation done.
No temporary file is removed after done.
thanks for reporting. I can confirm this bug to be present in Fedora 16. I will have a look at as soon as possible.
Created attachment 597071 [details]
Proposed patch to fix the issue
This patch should fix the issue when applied to the fedpkg repository. I'll build testing packages for you tomorrow.
There was a problem with the ported patch - it wasn't ported entirely and the ck_fcopy function was left behind.
Created attachment 597355 [details]
Proposed patch to fix the issue (changed function names)
I changed the patch a little bit more to reflect what the functions ck_fcmove and ck_fccopy do. I built a package with this patch on
so you can test it if you want to.
Thanks for the test package. It fixes the problem I reported here.
sed-4.2.1-9.fc16 has been submitted as an update for Fedora 16.
sed-4.2.1-10.fc17 has been submitted as an update for Fedora 17.
* should fix your issue,
* was pushed to the Fedora 17 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing sed-4.2.1-10.fc17'
as soon as you are able to.
Please go to the following url:
then log in and leave karma (feedback).
sed-4.2.1-10.fc17 has been pushed to the Fedora 17 stable repository. If problems still persist, please make note of it in this bug report.