Fix Int.MaxValue hash collision bug in ExternalAppendOnlyMap

The solution is to maintain the invariant that mergeHeap contains only non-empty
StreamBuffer's at the time next() is called.