kmod.attr: optimization: do not call strip_compress_sfx() twice
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
This commit is contained in:
parent
491a3411df
commit
5df3d6d58b
10
kmod.attr
10
kmod.attr
@ -15,16 +15,18 @@
|
||||
for l in io.lines(fn) do
|
||||
local builtin_mod = basename(l)
|
||||
printdep(builtin_mod)
|
||||
if strip_compress_sfx(builtin_mod) ~= builtin_mod then
|
||||
printdep(strip_compress_sfx(builtin_mod))
|
||||
local nocompr = strip_compress_sfx(builtin_mod)
|
||||
if nocompr ~= builtin_mod then
|
||||
printdep(nocompr)
|
||||
end
|
||||
end
|
||||
else
|
||||
local mod = string.match(bn, "%g+%.ko")
|
||||
if mod then
|
||||
printdep(mod)
|
||||
if strip_compress_sfx(mod) ~= mod then
|
||||
printdep(strip_compress_sfx(mod))
|
||||
local nocompr = strip_compress_sfx(mod)
|
||||
if nocompr ~= mod then
|
||||
printdep(nocompr)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user