diff options
author | wbond <will@wbond.net> | 2019-10-01 00:35:30 -0400 |
---|---|---|
committer | wbond <will@wbond.net> | 2019-10-01 00:35:30 -0400 |
commit | 011ab06123a33e914262617d6a784c1d95d53f0f (patch) | |
tree | c41e713e1cfa303cfca10f5d307952cc4fcb2811 | |
parent | c29117fd57deb80fb345cf76cad9d0d48e8bbf17 (diff) | |
download | asn1crypto-011ab06123a33e914262617d6a784c1d95d53f0f.tar.gz |
Prevent UnboundLocalError on empty asn1crypto.x509.IPAddress()
-rw-r--r-- | asn1crypto/x509.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/asn1crypto/x509.py b/asn1crypto/x509.py index 938bb41..9e4550e 100644 --- a/asn1crypto/x509.py +++ b/asn1crypto/x509.py @@ -389,6 +389,7 @@ class IPAddress(OctetString): if self._native is None: byte_string = self.__bytes__() byte_len = len(byte_string) + value = None cidr_int = None if byte_len in set([32, 16]): value = inet_ntop(socket.AF_INET6, byte_string[0:16]) |