-
assigned issue to
try-with-resources introduces an implicit null check which is flagged as an explicit check
Issue #64
new
As seen in this screenshot, try-with-resources checks if a resource is null before closing it. Though there are no explicit checks for null, this gets flagged by BugPicker.
33 public static boolean hasChildren(final Path path) throws IOException
34 {
35 try (DirectoryStream <Path> dirStream = Files.newDirectoryStream(path))
36 {
37 return dirStream.iterator().hasNext();
38 }
39 }
Unguarded local variable access (_ <: java.nio.file.DirectoryStream[@1;t=102]) though explicit test is done elsewhere.
location
fs.util. FsUtility { boolean hasChildren ( Path ) [ pc=8 line=37 ] }
unguarded access
location
fs.util. FsUtility { boolean hasChildren ( Path ) [ pc=63 line=38 ] }
guard
Comments (5)
-
repo owner -
repo owner - edited description
-
repo owner - edited description
- marked as task
-
repo owner - removed milestone
Removing milestone: 0.9.0-M1 (automated comment)
-
repo owner - removed version
Removing version: 0.9.0 (automated comment)
- Log in to comment