From 52be46abfca9a9b458d7455e891c937437b1356e Mon Sep 17 00:00:00 2001 From: Phil Jones Date: Sat, 19 Nov 2022 17:55:24 +0000 Subject: Cleanup some potentially flaky logic. Some of the string vec code was still assuming that it was just a list of `char *`s, rather than `struct scored_string`s. Correcting that makes future changes a little less error prone, and allows significantly simpler history sorting for tofi-run. --- src/string_vec.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/string_vec.h') diff --git a/src/string_vec.h b/src/string_vec.h index f4e0bb9..f3e840c 100644 --- a/src/string_vec.h +++ b/src/string_vec.h @@ -32,7 +32,7 @@ void string_vec_sort(struct string_vec *restrict vec); void string_vec_uniq(struct string_vec *restrict vec); -char **string_vec_find(struct string_vec *restrict vec, const char *str); +struct scored_string *string_vec_find(struct string_vec *restrict vec, const char *str); [[nodiscard("memory leaked")]] struct string_vec string_vec_filter( -- cgit v1.2.3