wireprotov2peer: rewrite character traversal to use slices
Otherwise on Python 3 we iterate over integers instead of a
bytes instance and the comparison fails.
Differential Revision: https://phab.mercurial-scm.org/D5698
BasedOnStyle: LLVM
IndentWidth: 8
UseTab: ForIndentation
BreakBeforeBraces: Linux
AllowShortIfStatementsOnASingleLine: false
IndentCaseLabels: false
AllowShortBlocksOnASingleLine: false
AllowShortFunctionsOnASingleLine: false
IncludeCategories:
- Regex: '^<'
Priority: 1
- Regex: '^"'
Priority: 2