index: do not consider just sorted base an error
index: fix race between data-sort and index lookup
index: whitespace cleanup
index: improved logging
XXX