]> git.ipfire.org Git - thirdparty/kmod.git/commit
libkmod: fix dumps for non-alias indexes
authorEmil Velikov <emil.l.velikov@gmail.com>
Mon, 4 Nov 2024 14:32:39 +0000 (14:32 +0000)
committerLucas De Marchi <lucas.de.marchi@gmail.com>
Thu, 7 Nov 2024 19:43:49 +0000 (13:43 -0600)
commit3d3421bce299777eeeb6ced3202602b5fc8131ac
tree933bdc43bc1d41b836843f827ac4b1a16a86356f
parent0930e7b49267ed989f375a2270f263a1cb00cc41
libkmod: fix dumps for non-alias indexes

For non-alias indexes prefix is an empty string, where
strbuf_pushchars() returns the number of characters added to the strbuf.

Since those are zero, we end up completely skipping the dump process.

Cc: Tobias Stoeckmann <tobias@stoeckmann.org>
Fixes: 889d02b1 ("libkmod: check strbuf return values")
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Link: https://github.com/kmod-project/kmod/pull/224
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
libkmod/libkmod-index.c