[
https://issues.apache.org/jira/browse/SLING-7358?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16316679#comment-16316679
]
ASF GitHub Bot commented on SLING-7358:
---------------------------------------
tteofili commented on issue #1: SLING-7358: FileDistributionPackageBuilder temp
directory fallback
URL:
https://github.com/apache/sling-org-apache-sling-distribution-core/pull/1#issuecomment-356043260
the PR looks good to me, except the Apache License header in
FileDistributionPackageBuilderTest is missing (mvn clean install fails).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
> FileDistributionPackageBuilder fails with no temp directory configured
> ----------------------------------------------------------------------
>
> Key: SLING-7358
> URL: https://issues.apache.org/jira/browse/SLING-7358
> Project: Sling
> Issue Type: Bug
> Components: Content Distribution
> Affects Versions: Content Distribution Core 0.2.10
> Reporter: Dirk Rudolph
> Priority: Minor
>
> When no temp directory is configured the
> [FileDistributionPackageBuilder|https://github.com/apache/sling-org-apache-sling-distribution-core/blob/master/src/main/java/org/apache/sling/distribution/packaging/impl/FileDistributionPackageBuilder.java#L86]
> uses null to create a new temp file which, according to the java docs will
> use the default temp directory.
> On the other hand [reading the file
> internally|https://github.com/apache/sling-org-apache-sling-distribution-core/blob/master/src/main/java/org/apache/sling/distribution/packaging/impl/FileDistributionPackageBuilder.java#L160]
> uses the {{File}} constructor passing {{null}} as directory to it. This
> causes a non-existing file to be returned.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)