Skip to content

Commit

Permalink
Update dname_compare signature
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeroen Koekkoek authored and k0ekk0ek committed Aug 2, 2024
1 parent f0374db commit d5efc59
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
6 changes: 5 additions & 1 deletion dname.c
Original file line number Diff line number Diff line change
Expand Up @@ -307,11 +307,15 @@ dname_is_subdomain(const dname_type *left, const dname_type *right)


int
dname_compare(const dname_type *left, const dname_type *right)
dname_compare(const void *a, const void *b)
{
int result;
uint8_t label_count;
uint8_t i;
const dname_type *left, *right;

left = a;
right = b;

assert(left);
assert(right);
Expand Down
3 changes: 2 additions & 1 deletion dname.h
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,9 @@ dname_label(const dname_type *dname, uint8_t label)
* RIGHT. The comparison is case sensitive.
*
* Pre: left != NULL && right != NULL
* left and right are dname_type*.
*/
int dname_compare(const dname_type *left, const dname_type *right);
int dname_compare(const void *left, const void *right);


/*
Expand Down

0 comments on commit d5efc59

Please sign in to comment.