Scanner: Deadlock on incorrectly identified files