From: James Jones Date: Tue, 17 Aug 2021 15:14:02 +0000 (-0500) Subject: Correct success returns for fr_lst_{insert, extract}() (#4187) X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5ff4cecac25ea3dbd3056799845662d7dd221330;p=thirdparty%2Ffreeradius-server.git Correct success returns for fr_lst_{insert, extract}() (#4187) This change makes them consistent with the heap functions, simplifying migration from heap to LST. --- diff --git a/src/lib/util/lst.c b/src/lib/util/lst.c index 5b1fd8223f7..e87cd073982 100644 --- a/src/lib/util/lst.c +++ b/src/lib/util/lst.c @@ -620,7 +620,7 @@ int fr_lst_extract(fr_lst_t *lst, void *data) } _fr_lst_extract(lst, 0, data); - return 1; + return 0; } int fr_lst_insert(fr_lst_t *lst, void *data) @@ -643,7 +643,7 @@ int fr_lst_insert(fr_lst_t *lst, void *data) } _fr_lst_insert(lst, 0, data); - return 1; + return 0; } fr_lst_index_t fr_lst_num_elements(fr_lst_t *lst)