kmod/shared
Tobias Stoeckmann 0c2bd66e6b shared: unify array trim handling
An error during array_realloc is always ignored if the idea
was to save memory by trimming an array.

Move two occurrences of same code into a single function for
easier reviewing.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Link: https://github.com/kmod-project/kmod/pull/68
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
2024-08-16 00:00:26 -05:00
..
.gitignore Move generic util functions to shared directory 2014-10-03 00:33:25 -03:00
array.c shared: unify array trim handling 2024-08-16 00:00:26 -05:00
array.h shared: switch array API to size_t 2024-08-16 00:00:00 -05:00
hash.c Drop the one line short description on sources 2024-07-26 13:41:56 -05:00
hash.h Move hash implementation to shared directory 2014-10-03 00:40:11 -03:00
macro.h Drop the one line short description on sources 2024-07-26 13:41:56 -05:00
missing.h Use portable implementation for basename API 2024-06-10 18:15:39 -05:00
scratchbuf.c Drop the one line short description on sources 2024-07-26 13:41:56 -05:00
scratchbuf.h shared: make scratchbuf_str static 2016-11-10 22:14:27 -02:00
strbuf.c Drop the one line short description on sources 2024-07-26 13:41:56 -05:00
strbuf.h shared: rename prefixes of strbuf functions 2014-10-11 13:25:51 -03:00
util.c Drop the one line short description on sources 2024-07-26 13:41:56 -05:00
util.h Fix typos 2024-08-15 23:06:21 -05:00