mirror of
https://github.com/gryf/wicd.git
synced 2026-03-01 14:15:46 +01:00
Merged 1.6-rworkman
This commit is contained in:
@@ -121,7 +121,8 @@ def GetWirelessInterfaces():
|
|||||||
def GetWiredInterfaces():
|
def GetWiredInterfaces():
|
||||||
""" Returns a list of wired interfaces on the system. """
|
""" Returns a list of wired interfaces on the system. """
|
||||||
basedir = '/sys/class/net/'
|
basedir = '/sys/class/net/'
|
||||||
return [iface for iface in os.listdir(basedir) if not 'wireless'
|
return [iface for iface in os.listdir(basedir)
|
||||||
|
if os.path.isdir(basedir + iface) and not 'wireless'
|
||||||
in os.listdir(basedir + iface) and
|
in os.listdir(basedir + iface) and
|
||||||
open(basedir + iface + "/type").readlines()[0].strip() == "1"]
|
open(basedir + iface + "/type").readlines()[0].strip() == "1"]
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user