Diffstat (limited to 'noncore/settings/networksettings/interfaces.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/settings/networksettings/interfaces.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/noncore/settings/networksettings/interfaces.cpp b/noncore/settings/networksettings/interfaces.cpp index 9155890..377a6db 100644 --- a/noncore/settings/networksettings/interfaces.cpp +++ b/noncore/settings/networksettings/interfaces.cpp @@ -53,3 +53,3 @@ QStringList Interfaces::getInterfaceList(){ QString line = (*it).simplifyWhiteSpace(); - if(line.contains(IFACE)){ + if(line.contains(IFACE) && line.at(0) != '#'){ line = line.mid(QString(IFACE).length() +1, line.length()); @@ -459,3 +459,3 @@ bool Interfaces::setStanza(QString stanza, QString option, QStringList::Iterator QString line = (*it).simplifyWhiteSpace(); - if(line.contains(stanza) && line.contains(option)){ + if(line.contains(stanza) && line.contains(option) && line.at(0) != '#'){ uint point = line.find(option); @@ -505,3 +505,3 @@ bool Interfaces::setOption(QStringList::Iterator start, QString option, QString } - if((*it).contains(option) && it != start){ + if((*it).contains(option) && it != start && (*it).at(0) != '#'){ // Found it in stanza so replace it. @@ -536,3 +536,3 @@ bool Interfaces::removeOption(QStringList::Iterator start, QString option, QStri } - if((*it).contains(option) && (*it).contains(value) &&it != start){ + if((*it).contains(option) && (*it).contains(value) && it != start && (*it).at(0) != '#'){ // Found it in stanza so replace it. @@ -589,3 +589,3 @@ QString Interfaces::getOption(QStringList::Iterator start, QString option, bool } - if((*it).contains(option)){ + if((*it).contains(option) && (*it).at(0) != '#'){ if(found) |