SERVER-8791 SERVER-9165 SERVER-9212 Fix Windows compile warning