diff options
author | peter <peter@FreeBSD.org> | 2002-04-11 10:00:44 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 2002-04-11 10:00:44 +0000 |
commit | a2bdc11625ac3ed770aed5f838725e3f00c2c279 (patch) | |
tree | 2ab1cf9c6a3b3de4e7f82347de7051764ea173e5 /sys/boot/common | |
parent | 63071c12c89590f82b59e00f581c33b3a2eba6e7 (diff) | |
download | FreeBSD-src-a2bdc11625ac3ed770aed5f838725e3f00c2c279.zip FreeBSD-src-a2bdc11625ac3ed770aed5f838725e3f00c2c279.tar.gz |
Bandaid for a buffer overrun in the module searching code. When breaking
up the module_path string, we would walk one past the end of the buffer.
This hurting ia64 originally, but it was probably also happening on i386
occasionally as well. The effects were usually harmless, it would add
bogus "binary" search directories to the places it actually looked for
files.
Diffstat (limited to 'sys/boot/common')
-rw-r--r-- | sys/boot/common/module.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/boot/common/module.c b/sys/boot/common/module.c index b294048..dbbf629 100644 --- a/sys/boot/common/module.c +++ b/sys/boot/common/module.c @@ -937,6 +937,8 @@ moduledir_rebuild(void) mdp->d_flags = 0; STAILQ_INSERT_TAIL(&moduledir_list, mdp, d_link); } + if (*ep == 0) + break; } /* * Delete unused directories if any |