Commit 8920990d by Michael DeHaan

Merge pull request #6097 from mattjeffery/bug/modprobe_normalise_name

Normalise the module name when comparing against the module names in /proc/modules
parents f0e23617 8131feaa
......@@ -60,8 +60,9 @@ def main():
try:
modules = open('/proc/modules')
present = False
module_name = args['name'].replace('-', '_') + ' '
for line in modules:
if line.startswith(args['name'] + ' '):
if line.startswith(module_name):
present = True
break
modules.close()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment