From 7f811943041a8b9afc9b90da3c273be554ab9805 Mon Sep 17 00:00:00 2001 From: Mooffie Date: Thu, 10 Nov 2016 22:26:54 +0200 Subject: [PATCH] (mc_search_run): document the return value. Signed-off-by: Andrew Borodin --- lib/search/search.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/lib/search/search.c b/lib/search/search.c index 88008ab9b..2e19ccf96 100644 --- a/lib/search/search.c +++ b/lib/search/search.c @@ -263,6 +263,19 @@ mc_search_prepare (mc_search_t * lc_mc_search) /* --------------------------------------------------------------------------------------------- */ +/** + * Carries out the search. + * + * Returns TRUE if found. + * + * Returns FALSE if not found. In this case, lc_mc_search->error reveals + * the reason: + * + * - MC_SEARCH_E_NOTFOUND: the pattern isn't in the subject string. + * - MC_SEARCH_E_ABORT: the user aborted the search. + * - For any other reason (but not for the above two!): the description + * is in lc_mc_search->error_str. + */ gboolean mc_search_run (mc_search_t * lc_mc_search, const void *user_data, gsize start_search, gsize end_search, gsize * found_len) -- 2.11.4.GIT