Mark smartlist_bsearch as taking a const list.

It does not modify the actual list.
This commit is contained in:
Mike Perry
2018-08-25 00:26:42 +00:00
parent be8e56c231
commit dac7d92918
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -628,7 +628,7 @@ smartlist_uniq(smartlist_t *sl,
* less than member, and greater than 0 if key is greater then member.
*/
void *
smartlist_bsearch(smartlist_t *sl, const void *key,
smartlist_bsearch(const smartlist_t *sl, const void *key,
int (*compare)(const void *key, const void **member))
{
int found, idx;
+1 -1
View File
@@ -120,7 +120,7 @@ const uint8_t *smartlist_get_most_frequent_digest256(smartlist_t *sl);
void smartlist_uniq_strings(smartlist_t *sl);
void smartlist_uniq_digests(smartlist_t *sl);
void smartlist_uniq_digests256(smartlist_t *sl);
void *smartlist_bsearch(smartlist_t *sl, const void *key,
void *smartlist_bsearch(const smartlist_t *sl, const void *key,
int (*compare)(const void *key, const void **member));
int smartlist_bsearch_idx(const smartlist_t *sl, const void *key,
int (*compare)(const void *key, const void **member),