You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Vitali Nashkevich (Jira)" <ji...@apache.org> on 2020/12/08 19:18:00 UTC

[jira] [Comment Edited] (VFS-790) VFS2 handles files with special characters incorrectly

    [ https://issues.apache.org/jira/browse/VFS-790?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17245154#comment-17245154 ] 

Vitali Nashkevich edited comment on VFS-790 at 12/8/20, 7:17 PM:
-----------------------------------------------------------------

Another interesting linkĀ [|[https://en.wikipedia.org/wiki/Internationalized_Resource_Identifier]]


was (Author: vnashkev):
Another interesting linkĀ [|[https://en.wikipedia.org/wiki/Internationalized_Resource_Identifierhttp://example.com|https://en.wikipedia.org/wiki/Internationalized_Resource_Identifier]]

> VFS2 handles files with special characters incorrectly
> ------------------------------------------------------
>
>                 Key: VFS-790
>                 URL: https://issues.apache.org/jira/browse/VFS-790
>             Project: Commons VFS
>          Issue Type: Bug
>    Affects Versions: 2.2, 2.7.0
>         Environment: windows 10
> java 8
> vfs 2.7
>            Reporter: Vitali Nashkevich
>            Priority: Major
>         Attachments: LocalFileProviderTest.java
>
>
> The following Testcase fails :
>  
> {code:java}
> @Test
> public final static void testLocalFile() 
> 	throws Exception
> {
> 	final String prefix = new String(new char[] { '\u0074', '\u0065', '\u00a0', '\u0074' });
> 	final File f = File.createTempFile(prefix + "-" , "-" + prefix);
> 	assert f.exists();
> 		
> 	final URI uri = f.toURI();
> 		
> 	try ( final FileSystemManager m = VFS.getManager() )
> 	{
> 		try ( final FileObject s = m.resolveFile(uri) )
> 		{
> 			try ( final FileContent sourceContent = s.getContent() )
> 			{
> 				final long size = sourceContent.getSize();
> 				assert size==f.length();
> 			}
> 		}
> 	}	
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)