Fix off-by-one error in setting invite/pledge bits
Update with various options for clang-3.6