blackbox: move _openlogfile to a separate method
This removes several `stat` syscalls for accessing `_bbvfs` and makes `ui`
object cleaner.
Differential Revision: https://phab.mercurial-scm.org/D769
% creating repo% add and commitC test.py% changeM test.py