Bug 367549 - Cannot drag-and-drop files from tar.gz within an epk archive
Summary: Cannot drag-and-drop files from tar.gz within an epk archive
Status: RESOLVED FIXED
Alias: None
Product: ark
Classification: Applications
Component: general (show other bugs)
Version: 16.04.3
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Elvis Angelaccio
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-08-19 09:45 UTC by Elvis Angelaccio
Modified: 2016-10-01 20:08 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In: 16.08.2


Attachments
test file (10.68 KB, application/x-deb)
2016-08-19 09:45 UTC, Elvis Angelaccio
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Elvis Angelaccio 2016-08-19 09:45:00 UTC
Test file attached.

Reproducible: Always

Steps to Reproduce:
1. ark base-0.8.target.epk
2. open data.tar.gz
3. drag-and-drop e.g. etc/nsswitch.conf to any folder 

Actual Results:  
Extraction of the entry:
    ‘/nsswitch.conf’
failed with the error message:
    Can't create '/nsswitch.conf'

Expected Results:  
nsswitch.conf is extracted to the destination folder.
Comment 1 Elvis Angelaccio 2016-08-19 09:45:26 UTC
Created attachment 100681 [details]
test file
Comment 2 Elvis Angelaccio 2016-08-19 09:46:23 UTC
epk files are basically renamed .deb files, but I can't reproduce it with an actual .deb archive.
Comment 3 Ragnar Thomsen 2016-10-01 19:27:57 UTC
Git commit bb9ede753623f7d3958f7a78985bb4142fbc0bb0 by Ragnar Thomsen.
Committed on 01/10/2016 at 19:24.
Pushed by rthomsen into branch 'Applications/16.08'.

Fix drag-and-drop extraction of parentless files

In some archives parent folders of some files might not be part of the
archive themselves, i.e. the archive does not contain separate entries
for them. In this case ArchiveModel creates ArchiveDirNodes for the
folders. However, the FileName and InternalID properties of these
folders do not get a trailing slash. This results in faulty root nodes
leading to e.g. broken drag-n-drop extraction of files within these
folders.

This diff simply appends a traling slash to the properties in
ArchiveModel::parentFor().
FIXED-IN: 16.08.2
Differential Revision: D2909

M  +1    -1    part/archivemodel.cpp

http://commits.kde.org/ark/bb9ede753623f7d3958f7a78985bb4142fbc0bb0