fix a few bugs.
Merge branch 'diffbot' of github.com:gigablast/open-source-search-engine into diffbot