diff options
author | Chris Hall <chris.hall@highwayman.com> | 2011-03-29 00:29:35 +0100 |
---|---|---|
committer | Chris Hall <chris.hall@highwayman.com> | 2011-03-29 00:29:35 +0100 |
commit | e20f7ccd9e110fcd5deb945f8d23922efd8b0822 (patch) | |
tree | 89b61ee61ac306817dc19b9313806bf2562b1c1b /lib/vector.c | |
parent | 6481583be322b0ba223a0140500a0a6d50546dd9 (diff) | |
download | quagga-ex14.tar.bz2 quagga-ex14.tar.xz |
Bring "ex" version up to date with 0.99.18ex14
Release: 0.99.18ex14
Also fixes issue with unknown attributes -- does not release them prematurely.
Contains the "bgpd: New show commands for improved view and address family support", which is post 0.99.18. (But not RFC 5082 GTSM.)
Diffstat (limited to 'lib/vector.c')
-rw-r--r-- | lib/vector.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/vector.c b/lib/vector.c index 646f19a5..83f289fe 100644 --- a/lib/vector.c +++ b/lib/vector.c @@ -987,7 +987,8 @@ vector_bsearch(vector v, vector_bsearch_cmp* cmp, const void* p_val, if (v->end <= 1) { - *result = (v->end == 0) ? -1 : cmp(&p_val, (const void**)&v->p_items[0]) ; + *result = (v->end == 0) ? -1 : + cmp(&p_val, (const void* const*)&v->p_items[0]) ; return 0 ; /* Stop dead if 0 or 1 items */ } ; @@ -996,12 +997,12 @@ vector_bsearch(vector v, vector_bsearch_cmp* cmp, const void* p_val, ih = v->end - 1 ; /* Pick off the edge cases: >= last and <= first. */ - if ((c = cmp(&p_val, (const void**)&v->p_items[ih])) >= 0) + if ((c = cmp(&p_val, (const void* const*)&v->p_items[ih])) >= 0) { *result = c ; /* 0 => found. +1 => val > last */ return ih ; /* return high index. */ } ; - if ((c = cmp(&p_val, (const void**)&v->p_items[il])) <= 0) + if ((c = cmp(&p_val, (const void* const*)&v->p_items[il])) <= 0) { *result = c ; /* 0 => found. -1 => val < first */ return il ; /* return low index. */ @@ -1018,7 +1019,7 @@ vector_bsearch(vector v, vector_bsearch_cmp* cmp, const void* p_val, return il ; /* return il: item[il] < val < item[il+1] */ } ; /* We now know that il < iv < ih */ - c = cmp(&p_val, (const void**)&v->p_items[iv]) ; + c = cmp(&p_val, (const void* const*)&v->p_items[iv]) ; if (c == 0) { *result = 0 ; |