fix OOM for large &n=1000000000 values when searching.
just alloc for the docids found, not the docids asked for.