]> git.ipfire.org Git - thirdparty/git.git/commit
string-list: optionally omit empty string pieces in string_list_split*()
authorJunio C Hamano <gitster@pobox.com>
Fri, 1 Aug 2025 22:04:22 +0000 (15:04 -0700)
committerJunio C Hamano <gitster@pobox.com>
Sun, 3 Aug 2025 05:34:45 +0000 (22:34 -0700)
commit27531efa41cfa882473513dd93e696a16f6eb87b
tree262567942f856b61a9a7f29ef210dc526c0b5293
parentf3a303aef017ad6e53fa44643d832a1fa0de0d91
string-list: optionally omit empty string pieces in string_list_split*()

Teach the unified split_string() machinery a new flag bit,
STRING_LIST_SPLIT_NONEMPTY, to cause empty split pieces to be
omitted from the resulting string list.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
string-list.c
string-list.h
t/unit-tests/u-string-list.c