-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[GAL-365] Allow for non-readable files inside Galleon installation #350
Conversation
@@ -162,7 +162,7 @@ private void initChildren(final FsEntry parent) throws IOException { | |||
} | |||
if(hasDirs) { | |||
for(FsEntry child : parent.getChildren()) { | |||
if(!child.dir) { | |||
if(!child.dir || !Files.isReadable(child.p)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@spyrkob , is it enough? DirectoryStream stream = Files.newDirectoryStream(parent.p) (line 155) should fail if the installation root directory contains non readable directory. No?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jfdenise my understanding is that if the parent directory has read permission, you're able to list all the children. The problem happens when trying to create the newDirectoryStream
for the child folder without read permission (line 168).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@spyrkob , ok.
@spyrkob , FYI, the failing tests on windows are related to this fix. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new tests are failing on windows.
I had to skip those tests on Windows as it doesn't seem possible to set the correct permissions on the test folders. |
@spyrkob , thank-you merged |
Issue: https://issues.redhat.com/browse/GAL-365