[Toybox] [PATCH 1/2] insmod: tiny cleanup.

enh enh at google.com
Sat Sep 11 11:34:36 PDT 2021


finit_module(2) was added in Linux 3.8, and even CentOS 7.2 has 3.10, so
we should be able to assume that now rather than working around its
possible absence (especially in the *build* environment). I've left the
runtime workaround for now, since we need that to support the stdin use
case anyway.

Also add a missing error check for a failure to read, so we can give a
more relevant error message (we can't use xreadfile() because we need to
know the resulting size).
---
 toys/other/insmod.c | 16 +++++-----------
 1 file changed, 5 insertions(+), 11 deletions(-)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.landley.net/pipermail/toybox-landley.net/attachments/20210911/fb743895/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-insmod-tiny-cleanup.patch
Type: text/x-patch
Size: 2255 bytes
Desc: not available
URL: <http://lists.landley.net/pipermail/toybox-landley.net/attachments/20210911/fb743895/attachment.bin>


More information about the Toybox mailing list