def replace_win_devices(name):
 if name:
  lname = name.lower()
  for dev in _DEVICES:
   if ((lname == dev) or lname.startswith((dev + '.'))):
    name = ('_' + name)
    break
 return name

def replace_win_devices ( name ) : if name : lname = name . lower ( ) for dev in _DEVICES : if ( ( lname == dev ) or lname . startswith ( ( dev + '.' ) ) ) : name = ( '_' + name ) break return name
remove reserved windows device names from a name .