]> git.ipfire.org Git - thirdparty/kmod.git/commit
depmod: Check amount of memories
authorTobias Stoeckmann <tobias@stoeckmann.org>
Mon, 30 Sep 2024 15:05:23 +0000 (17:05 +0200)
committerLucas De Marchi <lucas.de.marchi@gmail.com>
Tue, 1 Oct 2024 14:12:30 +0000 (09:12 -0500)
commitea16db2c0e3b5c3f3de82b517af9f91dc3e7de4e
treedd22f3c31a90ed5d2bc2f317418708fb607bc70c
parenta1186faeac14763d11872ec93b572738a7a7e09a
depmod: Check amount of memories

The code does not support 65535 or more modules. Since this value is
probably never reached, add a proper check after array building and
do not rely solely on an assert later in code path.

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/158
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
tools/depmod.c