[PATCH 4/6] Uset modinfo -F to get the patch directly, without parsing them out

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

 



---
 isys/isys.py |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/isys/isys.py b/isys/isys.py
index 94ce039..551887d 100755
--- a/isys/isys.py
+++ b/isys/isys.py
@@ -397,10 +397,8 @@ def modulesWithPaths():
     mods = []
     for modline in open("/proc/modules", "r"):
         modName, _ = modline.split(" ", 1)
-        modInfo = os.popen("modinfo '%s'" % (modName,)).readlines()
-        modPaths = [ line[9:].strip()
-            for line in modInfo
-            if line.startswith("filename:") ]
+        modInfo = os.popen("modinfo -F filename '%s'" % (modName,)).readlines()
+        modPaths = [ line.strip() for line in modInfo if line!="" ]
         mods.extend(modPaths)
     return mods
 
-- 
1.6.4.4

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux