# HG changeset patch # User Pierre-Yves David # Date 2014-08-29 10:51:00 # Node ID 7e6dd496d3278796737b18df8bac489c41dde3e8 # Parent 6d113cc7a31a244148590b8c624c24a557c8a8a2 wireprotocol: fix 'boolean' handling The encoding and decoding code were swapped. This is now fixed. diff --git a/mercurial/wireproto.py b/mercurial/wireproto.py --- a/mercurial/wireproto.py +++ b/mercurial/wireproto.py @@ -351,7 +351,7 @@ class wirepeer(peer.peerrepository): elif keytype == 'csv': value = ','.join(value) elif keytype == 'boolean': - value = bool(value) + value = '%i' % bool(value) elif keytype != 'plain': raise KeyError('unknown getbundle option type %s' % keytype) @@ -656,7 +656,7 @@ def getbundle(repo, proto, others): elif keytype == 'csv': opts[k] = set(v.split(',')) elif keytype == 'boolean': - opts[k] = '%i' % bool(v) + opts[k] = bool(v) elif keytype != 'plain': raise KeyError('unknown getbundle option type %s' % keytype)