Coverity reports warning
`warning[SC2164]: Use 'popd ... || exit' or 'popd ... || return' in case popd fails.`
This cannot happen in case of weak-modules, but makes no harm.
Signed-off-by: Yauheni Kaliuta <ykaliuta@redhat.com>
Coverity reports warning for splitting mods=($i)
`Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.`
Even if it can not cause problems for weak-modules case where the
list is coming from modules.dep, use the recommended read -a method.
Signed-off-by: Yauheni Kaliuta <ykaliuta@redhat.com>