[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#532745: initramfs-tools: /etc/initramfs-tools/modules - Last module without extra newline not added to image



On Thu, 11 Jun 2009, sftf wrote:

> In /etc/initramfs-tools/modules
> if after the last module has no extra line, then the module is not included in the initramfs's image.
> 
> Suggestions:
> #1 Simply add reminder to /etc/initramfs-tools/modules.
> or
> #2 Add newline at the end of file and stripe any empty lines:

thanks for the report and the sent patch.

solved it according to the code in /etc/init.d/modules-init-tools
see http://git.debian.org/?p=kernel/initramfs-tools.git;a=summary

 
> --- cut --------------------------------------------------
> --- hook-functions      2008-12-18 22:41:11.000000000 +0600
> +++ hook-functions.new  2009-06-11 16:06:08.951439683 +0700
> @@ -33,7 +33,8 @@
>                 return
>         fi
> 
> -       sed -e '/^#/d' ${1} | while read module rest; do
> +       sed -e '/^#/d' -e '${/^$/!s/$/\
> +           /;}' ${1} | sed -e '/^$/d'| while read module rest; do
>                 force_load "${module}" "${rest}"
>         done
>  }
> --- cut --------------------------------------------------
> 




Reply to: