Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 597071 Details for
Bug 832855
Teporary file is left behind with the sed option '--copy'
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
Proposed patch to fix the issue
el7-sed-copy.patch (text/plain), 1.90 KB, created by
Martin Bříza
on 2012-07-09 12:58:29 UTC
(
hide
)
Description:
Proposed patch to fix the issue
Filename:
MIME Type:
Creator:
Martin Bříza
Created:
2012-07-09 12:58:29 UTC
Size:
1.90 KB
patch
obsolete
>diff --git a/sed-4.2.1-copy.patch b/sed-4.2.1-copy.patch >index 48bde87..6d19292 100644 >--- a/sed-4.2.1-copy.patch >+++ b/sed-4.2.1-copy.patch >@@ -35,7 +35,7 @@ index af8c4d2..c05b418 100644 > } > > - ck_rename (input->out_file_name, target_name, input->out_file_name); >-+ (copy_instead_of_rename?ck_fcmove:ck_rename) >++ (copy_instead_of_rename?ck_fcopy:ck_rename) > + (input->out_file_name, target_name, input->out_file_name); > free (input->out_file_name); > } >@@ -135,7 +135,7 @@ index 241ef1d..ebe6030 100644 > > #include "utils.h" > #include "pathmax.h" >-@@ -408,33 +409,99 @@ follow_symlink(const char *fname) >+@@ -408,33 +409,109 @@ follow_symlink(const char *fname) > return fname; > #endif /* ENABLE_FOLLOW_SYMLINKS */ > } >@@ -245,6 +245,16 @@ index 241ef1d..ebe6030 100644 > + if (!_unlink_if_fail (_copy (from, to), unlink_if_fail)) > + panic (_("cannot copy %s to %s: %s"), from, to, strerror (errno)); > +} >++ >++/* Copy contents between files, and then unlink the source. */ >++void >++ck_fcopy (from, to, unlink_if_fail) >++ const char *from, *to; >++ const char *unlink_if_fail; >++{ >++ ck_fcmove (from, to, unlink_if_fail); >++ ck_unlink (from); >++} > > > >@@ -252,11 +262,12 @@ diff --git a/sed/utils.h b/sed/utils.h > index d3f431d..b915596 100644 > --- a/sed/utils.h > +++ b/sed/utils.h >-@@ -32,6 +32,7 @@ const char *follow_symlink P_((const char *path)); >+@@ -32,6 +32,8 @@ const char *follow_symlink P_((const char *path)); > size_t ck_getline P_((char **text, size_t *buflen, FILE *stream)); > FILE * ck_mkstemp P_((char **p_filename, char *tmpdir, char *base)); > void ck_rename P_((const char *from, const char *to, const char *unlink_if_fail)); > +void ck_fcmove P_((const char *from, const char *to, const char *unlink_if_fail)); >++void ck_fcopy P_((const char *from, const char *to, const char *unlink_if_fail)); > > VOID *ck_malloc P_((size_t size)); > VOID *xmalloc P_((size_t size));
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 832855
:
597071
|
597355