rpm: use "create+rename" method of replacing existing files
Users were reporting getting errors like "ls: error while loading shared libraries: libc.so.6: ELF load command past end of file" while rpm was unpacking glibc tarball. Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
@@ -242,8 +242,8 @@ static void extract_cpio(int fd, const char *source_rpm)
|
||||
/* compat: overwrite existing files.
|
||||
* try "rpm -i foo.src.rpm" few times in a row -
|
||||
* standard rpm will not complain.
|
||||
* (TODO? real rpm creates "file;1234" and then renames it) */
|
||||
| ARCHIVE_UNLINK_OLD;
|
||||
*/
|
||||
| ARCHIVE_REPLACE_VIA_RENAME;
|
||||
archive_handle->src_fd = fd;
|
||||
/*archive_handle->offset = 0; - init_handle() did it */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user