diff options
author | Theo Buehler <tb@cvs.openbsd.org> | 2021-12-24 10:09:45 +0000 |
---|---|---|
committer | Theo Buehler <tb@cvs.openbsd.org> | 2021-12-24 10:09:45 +0000 |
commit | c9ee81cb3190022a08559729e1766b12880aed49 (patch) | |
tree | 77417981a10d327188c522b8c9c847761fe4fe33 /lib/libcrypto/x509 | |
parent | 4a759925d37cb8d3bce769b41318564bd91edf2f (diff) |
Fix a typo in a comment and add some empty lines for readability
Diffstat (limited to 'lib/libcrypto/x509')
-rw-r--r-- | lib/libcrypto/x509/x509_addr.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/libcrypto/x509/x509_addr.c b/lib/libcrypto/x509/x509_addr.c index 5512f310e12..db9ea089f67 100644 --- a/lib/libcrypto/x509/x509_addr.c +++ b/lib/libcrypto/x509/x509_addr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_addr.c,v 1.24 2021/12/24 02:02:37 tb Exp $ */ +/* $OpenBSD: x509_addr.c,v 1.25 2021/12/24 10:09:44 tb Exp $ */ /* * Contributed to the OpenSSL Project by the American Registry for * Internet Numbers ("ARIN"). @@ -1380,19 +1380,23 @@ const X509V3_EXT_METHOD v3_addr = { }; /* - * Figure out whether extension sues inheritance. + * Figure out whether extension uses inheritance. */ int X509v3_addr_inherits(IPAddrBlocks *addr) { int i; + if (addr == NULL) return 0; + for (i = 0; i < sk_IPAddressFamily_num(addr); i++) { IPAddressFamily *f = sk_IPAddressFamily_value(addr, i); + if (f->ipAddressChoice->type == IPAddressChoice_inherit) return 1; } + return 0; } |