/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/git/revspec.py

  • Committer: Jelmer Vernooij
  • Date: 2019-03-04 05:10:44 UTC
  • mfrom: (7293 work)
  • mto: This revision was merged to the branch mainline in revision 7294.
  • Revision ID: jelmer@jelmer.uk-20190304051044-vph4s8p9qvpy2qe9
Merge trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
40
40
    :param hex: Hex string to validate
41
41
    :return: Boolean
42
42
    """
43
 
    import binascii
44
43
    try:
45
 
        binascii.unhexlify(hex)
46
 
    except TypeError:
47
 
        return False
48
 
    except binascii.Error:
 
44
        int(hex, 16)
 
45
    except ValueError:
49
46
        return False
50
47
    else:
51
48
        return True