Last Comment Bug 767916 - Decode percent encoding on non-ASCII filename when saving a video snapshot.
: Decode percent encoding on non-ASCII filename when saving a video snapshot.
Status: RESOLVED FIXED
[good first bug][mentor=IanN][lang=js...
:
Product: SeaMonkey
Classification: Client Software
Component: Download & File Handling (show other bugs)
: Trunk
: All All
: -- normal (vote)
: seamonkey2.13
Assigned To: Ekanan Ketunuti
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-06-25 03:19 PDT by Philip Chee
Modified: 2012-07-07 15:42 PDT (History)
3 users (show)
ryanvm: in‑testsuite-
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---


Attachments
patch (1.29 KB, patch)
2012-06-27 20:55 PDT, Ekanan Ketunuti
iann_bugzilla: review+
Details | Diff | Review

Description Philip Chee 2012-06-25 03:19:42 PDT
From Firefox Bug 734027 (Non-ASCII filename is shown as escaped unicode when saving a snapshot from video):

> Steps to reproduce:
> 1. Give video file Non-ASCII filename, for example: Basilique du Sacré-Cœur de 
> Montmartre.ogg
> 2. Play this file in Firefox
> 3. Right click on the video and select "Save Snapshot as..."
> 
> Actual result:
> Snapshot file shows escaped unicode instead of non ASCII characters
> 
> Expected result:
> Snapshot file name should contain the correct non-ascii characters.

Simple one line fix. See Firefox attachment 604004 [details] [diff] [review]:
> -        name = url.fileBaseName + ".jpg";
> +        name = decodeURI(url.fileBaseName) + ".jpg";

MXR shows the location of the equivalent SeaMonkey code:
<http://mxr.mozilla.org/comm-central/search?string=fileBaseName+%2B+".jpg"&find=%2Fsuite%2F&findi=&filter=^[^\0]*%24&hitlimit=&tree=comm-central>
Comment 1 Ekanan Ketunuti 2012-06-27 20:55:37 PDT
Created attachment 637371 [details] [diff] [review]
patch
Comment 2 Ian Neal 2012-07-07 07:00:34 PDT
Comment on attachment 637371 [details] [diff] [review]
patch

r=me, thanks for the patch
Comment 3 Philip Chee 2012-07-07 09:21:52 PDT
Hi Ekanan Ketunuti! Do you have checkin access to comm-central or do you need assistance checking this patch in?
Comment 4 Ryan VanderMeulen [:RyanVM] 2012-07-07 15:42:28 PDT
https://hg.mozilla.org/comm-central/rev/4c32741c3951

Note You need to log in before you can comment on or make changes to this bug.