Commit 5e9c7fb1 authored by Dafydd Harries's avatar Dafydd Harries

address_equal: don't compare irrelevant bits

darcs-hash:20070122160429-c9803-ec73f72437c16baba49049f8f2d08958ee0416d2.gz
parent 99f1ac5f
......@@ -62,7 +62,13 @@ address_to_string (Address *addr)
gboolean
address_equal (Address *a, Address *b)
{
return memcmp (a, b, sizeof (Address)) == 0;
if (a->type != b->type)
return FALSE;
if (a->type == ADDRESS_TYPE_IPV4)
return a->addr_ipv4 == b->addr_ipv4;
g_assert_not_reached ();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment