(heim_integer_cmp): make it work with negative numbers.

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16580 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2006-01-18 13:22:11 +00:00
parent b918f2f353
commit 35e8a7b886

View File

@@ -74,10 +74,10 @@ heim_bit_string_cmp(const heim_bit_string *p, const heim_bit_string *q)
int
heim_integer_cmp(const heim_integer *p, const heim_integer *q)
{
if (p->negative != q->negative)
return q->negative - p->negative;
if (p->length != q->length)
return p->length - q->length;
if (p->negative != q->negative)
return p->negative - q->negative;
return memcmp(p->data, q->data, p->length);
}