464555 - ALPN module download attempts to download jar before dir exists
+ Ensure directory exists for output before download is attempted.
This commit is contained in:
parent
0e2b1856b5
commit
05784f46b4
|
@ -251,11 +251,15 @@ public class BaseBuilder
|
||||||
{
|
{
|
||||||
if (startArgs.isDownload() && (arg.uri != null))
|
if (startArgs.isDownload() && (arg.uri != null))
|
||||||
{
|
{
|
||||||
|
// now on copy/download paths (be safe above all else)
|
||||||
if (!file.startsWith(baseHome.getBasePath()))
|
if (!file.startsWith(baseHome.getBasePath()))
|
||||||
{
|
{
|
||||||
throw new IOException("For security reasons, Jetty start is unable to process file resource not in ${jetty.base} - " + file);
|
throw new IOException("For security reasons, Jetty start is unable to process maven file resource not in ${jetty.base} - " + file);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// make the directories in ${jetty.base} that we need
|
||||||
|
FS.ensureDirectoryExists(file.getParent());
|
||||||
|
|
||||||
URI uri = URI.create(arg.uri);
|
URI uri = URI.create(arg.uri);
|
||||||
|
|
||||||
// Process via initializers
|
// Process via initializers
|
||||||
|
|
|
@ -108,11 +108,6 @@ public class MavenLocalRepoFileInitializer extends UriFileInitializer implements
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!file.startsWith(baseHome.getBasePath()))
|
|
||||||
{
|
|
||||||
throw new IOException("For security reasons, Jetty start is unable to process maven file resource not in ${jetty.base} - " + file);
|
|
||||||
}
|
|
||||||
|
|
||||||
// If using local repository
|
// If using local repository
|
||||||
if (this.localRepositoryDir != null)
|
if (this.localRepositoryDir != null)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue