]> git.hungrycats.org Git - linux/commit
[PATCH] check for truncated modules
authorAndrew Morton <akpm@osdl.org>
Tue, 20 Jan 2004 11:11:42 +0000 (03:11 -0800)
committerLinus Torvalds <torvalds@home.osdl.org>
Tue, 20 Jan 2004 11:11:42 +0000 (03:11 -0800)
commit8413db43a01d52c87643b344a0996d16af75d568
tree9f63da6eb57af3c824d1b62083e104b337da5997
parent74ebb0066d038bb9792d76ee005de3e8f60c1085
[PATCH] check for truncated modules

From: Rusty Russell <rusty@rustcorp.com.au>

I *do* want to add a check for a truncated module, since that's probably
the most common case (^C on "make modules_install").  But I don't want to
double the size of module.c with every check I can think of.

tested with:
# bs=0; while [ $bs -lt 3764 ]; do
   dd if=dummy.ko bs=$bs count=1 2>/dev/null | insmod -;
   bs=`expr $bs + 1`;
  done
kernel/module.c