Set comparison function in v3_add_canonize().
[openssl.git] / crypto / x509v3 / v3_addr.c
index 65371051084863824d4b5dbcdcea7c8959ff1375..16eaa730f53f5ba8dfcbd831fcecc7ceeed4db5e 100644 (file)
@@ -877,6 +877,7 @@ int v3_addr_canonize(IPAddrBlocks *addr)
                                    v3_addr_get_afi(f)))
       return 0;
   }
                                    v3_addr_get_afi(f)))
       return 0;
   }
+  sk_IPAddressFamily_set_cmp_func(addr, IPAddressFamily_cmp);
   sk_IPAddressFamily_sort(addr);
   assert(v3_addr_is_canonical(addr));
   return 1;
   sk_IPAddressFamily_sort(addr);
   assert(v3_addr_is_canonical(addr));
   return 1;