hammer2 - correct saveoff in hammer2_vop_readdir()
authorMatthew Dillon <dillon@apollo.backplane.com>
Tue, 14 Feb 2012 05:22:01 +0000 (21:22 -0800)
committerMatthew Dillon <dillon@apollo.backplane.com>
Tue, 14 Feb 2012 05:22:01 +0000 (21:22 -0800)
commit028a55bb322149dbe76d315fcb4b3d878694f2b0
tree183f32e596b30897ee08e4c4b9ad77a4db77f373
parenta56fb0785c095bf848d5fb480a93677f85b56733
hammer2 - correct saveoff in hammer2_vop_readdir()

* When terminating a search early read the next entry and set save_off
  to that, instead of setting it to the last returned entry's key + 1.

  This ensures an exact match when the search resume.  This could create
  problems in the future but for now its a quick way to track the
  directory scan due to the fully-associative nature of the on-media
  blockref arrays.

  (In the future we may have to sort the fully associative array on-media
  to really solve the issue).

* This corrects repeated entries in 'ls' output.
sys/vfs/hammer2/hammer2_vnops.c