problem with non-ascii characters in file path

Bug #657703 reported by Beat Trachsler
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Firefogg
Confirmed
Undecided
Unassigned
Nominated for Trunk by Beat Trachsler

Bug Description

I have discovered that Firefogg has a problem with the use of umlauts (= non-ascii characters used in certain European languages) in filenames and in the directory path. By looking at the code in Firefogg.js (version 1.2.12) I have found the reason for this problem:
The method encodeUtf8 at line 2322 is outdated as you can see at https://developer.mozilla.org/en/XPCOM_Interface_Reference/nsIFile#Remarks
Attributes of nsIFile and nsILocalFile like for instance 'path' are always UTF-16 encoded. So you should not try to encode them twice.

To resolve this problem one can simply eliminate the method encodeUtf8 or replace its body by 'return string;'. Since it is only used to encode input and output file path this fixes the bug without causing other problems. I have already tested this.

remark: I have noticed that this problem occurs also with Firefogg 2.0.x für Firefox 4 beta. But unfortunately there I can't see the reason.

Revision history for this message
Beat Trachsler (beat-trachsler) wrote :
Revision history for this message
j^ (j) wrote :

Instead of sending the full file, could you send a patch against bzr. (bzr diff).
In Firefogg 2.0.x encodeUtf8 is no longer used, and non ascii should work since the last version

which os do you have the problem? I added encodeUtf8 due to problems on win32.

Revision history for this message
j^ (j) wrote :

ok, just looked through the 1.2.x branch and will test with non ascii filenames to see if it works like that.
the problem was mostly with the IPC module and utf-8. in Firefogg 2.x this is is fixed and encodeUtf8 is not used.

Revision history for this message
Beat Trachsler (beat-trachsler) wrote :

Ok. I see your point. But the problem occurs under Windows Xp and Windows7 (32bit and 64bit version). For Firefogg 1.2.x my fix will work. But I do not understand either why I got exactly the same problem with Firefogg 2.x. Tell me please whether you need further info from my part.

Revision history for this message
j^ (j) wrote :

2.x no longer uses encodeUtf8, there was an unrelated problem with non ascii names in 2.x which should have been fixed in 2.0.03, if its still in 2.0.03 please let me know, will have to do further tests on windows in that case.

Revision history for this message
Beat Trachsler (beat-trachsler) wrote :

Well then. Of course it will suffice to fix it for Firefogg 2.x. As you might remember it's this new version I am finally interested in for my image sequences. Thank's a lot for your very fast replies and your explanations.

j^ (j)
Changed in firefogg:
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.