Merge remote-tracking branch 'origin/jetty-9.4.x'

This commit is contained in:
Greg Wilkins 2016-07-06 16:48:33 +10:00
commit 40f816256b
1 changed files with 3 additions and 2 deletions

View File

@ -33,6 +33,7 @@ import java.nio.file.Files;
import java.nio.file.InvalidPathException;
import java.nio.file.LinkOption;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.nio.file.StandardOpenOption;
import java.nio.file.attribute.FileTime;
import java.util.ArrayList;
@ -83,7 +84,7 @@ public class PathResource extends Resource
try
{
if (Files.isSymbolicLink(path))
return Files.readSymbolicLink(path);
return path.getParent().resolve(Files.readSymbolicLink(path));
if (Files.exists(path))
{
Path real = abs.toRealPath(FOLLOW_LINKS);
@ -229,7 +230,7 @@ public class PathResource extends Resource
Path path;
try
{
path = new File(uri).toPath();
path = Paths.get(uri);
}
catch (InvalidPathException e)
{