base: fix error_cmp
Fix the numeric error value comparison performed by error_cmp(). Identified by AppChecker and previously fixed by Darwin. Change-Id: I0a72fd381bef0b34b7e7d155bfff03ab4196d38e
This commit is contained in:
@@ -53,8 +53,8 @@ static int
|
|||||||
error_cmp(void *a, void *b)
|
error_cmp(void *a, void *b)
|
||||||
{
|
{
|
||||||
struct heim_error *ap = a, *bp = b;
|
struct heim_error *ap = a, *bp = b;
|
||||||
if (ap->error_code == ap->error_code)
|
if (ap->error_code == bp->error_code)
|
||||||
return ap->error_code - ap->error_code;
|
return 0;
|
||||||
return heim_cmp(ap->msg, bp->msg);
|
return heim_cmp(ap->msg, bp->msg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user