commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <seb...@gmail.com>
Subject Re: [VFS][SFTP] access path containing %0
Date Tue, 14 Sep 2010 14:37:30 GMT
On 14 September 2010 15:27, Nicolas Delsaux <nicolas.delsaux@gmail.com> wrote:
> On Tue, Sep 14, 2010 at 4:03 PM, sebb <sebbaz@gmail.com> wrote:
>>
>> If the path really contains:
>>
>> /mnt/data/data_files/path%0/
>
> Oh yes it does, and I know it's a bad idea.
>>
>> then try using
>>
>> /mnt/data/data_files/path%250/
>>
>> where % is replaced by %25.
>
> it works !
> But isn't there any way to make that work with URLEncoder ? Indeed, I
> already use the url encoder to transform whitespaces and other non-url
> characters, and i would like to avoid too much complicated code ...

So just make sure that you also encode literal % characters as well.

Note that the path

/mnt/data/data_files/path%0/System%20Folder/etc.

is partially URL-encoded already; encoding it again will cause problems.

>>
>>
>>> Thanks
>>>
>>> --
>>> Nicolas Delsaux
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
>>> For additional commands, e-mail: user-help@commons.apache.org
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
>> For additional commands, e-mail: user-help@commons.apache.org
>>
>>
>
>
>
> --
> Nicolas Delsaux
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
> For additional commands, e-mail: user-help@commons.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org


Mime
View raw message