Minor tidyups to prevent some clang warnings.
Fixes for handling range requests while also multi-threading.