Commit 7b6fe2ab 7b6fe2abc7d5352f14aa54d50f8bc41660ea32dc by Sergey Poznyakoff

Minor change

* include/mailutils/list.h (mu_list_remove)
(mu_list_remove_nd): Second arg is const.
* libmailutils/list/remove.c: Likewise.
1 parent c78ceb5d
......@@ -114,10 +114,10 @@ int mu_list_insert (mu_list_t _list, void *_item, void *_new_item,
int _insert_before);
/* Remove _item from _list and deallocate any memory associated with it
using the `destroy_item' method. */
int mu_list_remove (mu_list_t _list, void *_item);
int mu_list_remove (mu_list_t _list, const void *_item);
/* A non-destructive version of mu_list_remove: removes the _item but does
not deallocate it. */
int mu_list_remove_nd (mu_list_t _list, void *_item);
int mu_list_remove_nd (mu_list_t _list, const void *_item);
/* Remove Nth element from the list. */
int mu_list_remove_nth (mu_list_t list, size_t n);
/* Remove Nth element from the list, non-destructive. */
......
......@@ -24,7 +24,7 @@
#include <mailutils/errno.h>
int
mu_list_remove (mu_list_t list, void *item)
mu_list_remove (mu_list_t list, const void *item)
{
struct list_data *current;
mu_list_comparator_t comp;
......@@ -56,7 +56,7 @@ mu_list_remove (mu_list_t list, void *item)
}
int
mu_list_remove_nd (mu_list_t list, void *item)
mu_list_remove_nd (mu_list_t list, const void *item)
{
mu_list_destroy_item_t dptr = mu_list_set_destroy_item (list, NULL);
int rc = mu_list_remove (list, item);
......