Review Request 124050: [Ark] Check if file exists before attempting to preview it
Ragnar Thomsen
rthomsen6 at gmail.com
Wed Jun 10 09:35:50 UTC 2015
> On June 9, 2015, 5:03 p.m., Raphael Kubo da Costa wrote:
> > What backtrace are you getting for your crash?
> >
> > I've just tried the KDE4 version with the file you mentioned and it does not crash, though the previewed file is shown as a new file instead.
>
> Ragnar Thomsen wrote:
> After the fix in commit 901593b59e8b6c684f8e823f410e41c939b08b99, the file is also previewed as a new file for me. I guess the proper way to address this would be that the clizip plugin should generate an error during extraction of the file.
>
> Raphael Kubo da Costa wrote:
> I think so, or we just switch away from infozip altogether as we were discussing yesterday. I feel like adding this kind of check in this method is too late and is most likely just working around a symptom of a larger problem anyway.
I will discard this RR and submit a new one that switches to p7zip for zip archives.
> On June 9, 2015, 5:03 p.m., Raphael Kubo da Costa wrote:
> > part/arkviewer.cpp, line 103
> > <https://git.reviewboard.kde.org/r/124050/diff/1/?file=379387#file379387line103>
> >
> > User messages should never have exclamation marks.
>
> Ragnar Thomsen wrote:
> Are there any KDE guidelines for message boxes, etc?
>
> Raphael Kubo da Costa wrote:
> There is this one at least: https://techbase.kde.org/Projects/Usability/HIG/Exclamation_points
Thanks :)
- Ragnar
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/124050/#review81335
-----------------------------------------------------------
On June 9, 2015, 4:36 p.m., Ragnar Thomsen wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/124050/
> -----------------------------------------------------------
>
> (Updated June 9, 2015, 4:36 p.m.)
>
>
> Review request for KDE Utils and Raphael Kubo da Costa.
>
>
> Repository: ark
>
>
> Description
> -------
>
> Attempting to preview a file that doesn't exist in the temporary directory crashes Ark. Ideally, this should not happen because only files that exist in an archive should be presented in the QTreeView. However, for the clizip plugin at least, files with filenames containing special characters cause this plugin to not find the file and hence not extract it, and Ark crashes attempting to view it.
>
> This patch adds a simple check to see if the file exists in the temporary directory before attempting to view it. If the file doesn't exist (e.g. could not be extracted by clizip), a KMessageBox::error() is displayed. Also an error is printed in console output.
>
>
> Diffs
> -----
>
> part/arkviewer.cpp 2276c5e
>
> Diff: https://git.reviewboard.kde.org/r/124050/diff/
>
>
> Testing
> -------
>
> Tested with the Zip archive provided in https://bugs.kde.org/show_bug.cgi?id=345519.
>
>
> Thanks,
>
> Ragnar Thomsen
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-utils-devel/attachments/20150610/4521baf0/attachment.html>
More information about the Kde-utils-devel
mailing list