Fixing PathWatcher root path handling on Windows
This commit is contained in:
parent
3a0a85ebc9
commit
b87db668c7
|
@ -376,11 +376,16 @@ public class PathWatcher extends AbstractLifeCycle implements Runnable
|
||||||
boolean needDelim = false;
|
boolean needDelim = false;
|
||||||
|
|
||||||
// Add root (aka "C:\" for Windows)
|
// Add root (aka "C:\" for Windows)
|
||||||
if (path.getRoot() != null)
|
Path root = path.getRoot();
|
||||||
|
if (root != null)
|
||||||
{
|
{
|
||||||
for (char c : path.getRoot().toString().toCharArray())
|
if (NOISY_LOG.isDebugEnabled())
|
||||||
{
|
{
|
||||||
if (c != '\\')
|
NOISY_LOG.debug("Path: {} -> Root: {}",path,root);
|
||||||
|
}
|
||||||
|
for (char c : root.toString().toCharArray())
|
||||||
|
{
|
||||||
|
if (c == '\\')
|
||||||
{
|
{
|
||||||
s.append(PATTERN_SEP);
|
s.append(PATTERN_SEP);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,4 +2,4 @@
|
||||||
org.eclipse.jetty.util.log.class=org.eclipse.jetty.util.log.StdErrLog
|
org.eclipse.jetty.util.log.class=org.eclipse.jetty.util.log.StdErrLog
|
||||||
#org.eclipse.jetty.util.LEVEL=DEBUG
|
#org.eclipse.jetty.util.LEVEL=DEBUG
|
||||||
|
|
||||||
org.eclipse.jetty.util.PathWatcher.Noisy.LEVEL=OFF
|
#org.eclipse.jetty.util.PathWatcher.Noisy.LEVEL=OFF
|
||||||
|
|
Loading…
Reference in New Issue