You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Whilst studying Issue #3744, I have come to suspect that the algorithm in Files#walk to detect file
system cycles and throw FileSystemLoopException can report both false positives and, worse,
false negatives (i.e. loop without termination).
Files#find uses walk(), so it is suspect also.
I think I must plead guilty on this one, even in a community with a ego-less programming norm.
I am currently working on File.walkFileTree. If my suspicions about Files#walk tree bear out
I hope to fold the loop detection algorithm from there into its sibling Files#walk.
This is going to take a long while, so no problem if somebody gets there before me.
Hint: consider back-edges visited, where a back-edge can be a directory ancestor
of a link used to get to the current path or such a link itself.
The text was updated successfully, but these errors were encountered:
merged PR #3917 fixed a series of bugs with symlink cycle detection (Thank you Wojciech!).
In particular, it solved my concerns with false positives where a symlink referred to a previously visited regular file.
I think it also fixed my concern with false negatives.
I will open another Issue detailing two specific defects which still exist. Rome was not built in a day.
Whilst studying Issue #3744, I have come to suspect that the algorithm in
Files#walk
to detect filesystem cycles and throw
FileSystemLoopException
can report both false positives and, worse,false negatives (i.e. loop without termination).
Files#find
useswalk()
, so it is suspect also.I think I must plead guilty on this one, even in a community with a ego-less programming norm.
I am currently working on
File.walkFileTree
. If my suspicions aboutFiles#walk
tree bear outI hope to fold the loop detection algorithm from there into its sibling
Files#walk
.This is going to take a long while, so no problem if somebody gets there before me.
Hint: consider back-edges visited, where a back-edge can be a directory ancestor
of a link used to get to the current path or such a link itself.
The text was updated successfully, but these errors were encountered: