Fix non-recursive directory sweeping.