Relates :
|
final boolean isInvalid() { if (status == null) { status = (this.path.indexOf('\u0000') < 0) ? PathStatus.CHECKED : PathStatus.INVALID; } return status == PathStatus.INVALID; } If the reads to "status" are reordered and another thread writes to "status", the return value can be wrong. Reading "status" to a local variable fixes the issue.
|