summaryrefslogtreecommitdiff
path: root/noncore/settings/networksettings/interfaces/interfacesetupimp.cpp
Side-by-side diff
Diffstat (limited to 'noncore/settings/networksettings/interfaces/interfacesetupimp.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/settings/networksettings/interfaces/interfacesetupimp.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/noncore/settings/networksettings/interfaces/interfacesetupimp.cpp b/noncore/settings/networksettings/interfaces/interfacesetupimp.cpp
index e844d8a..78466d0 100644
--- a/noncore/settings/networksettings/interfaces/interfacesetupimp.cpp
+++ b/noncore/settings/networksettings/interfaces/interfacesetupimp.cpp
@@ -62,49 +62,49 @@ bool InterfaceSetupImp::saveChanges(){
restart << "sh";
restart << "-c";
restart << ifup;
OWait *owait = new OWait();
Global::statusMessage( tr( "Restarting interface" ) );
owait->show();
qApp->processEvents();
if (!restart.start(OProcess::Block, OProcess::NoCommunication) ) {
qWarning("unstable to spawn ifdown/ifup");
}
owait->hide();
delete owait;
interface->refresh();
}
return true;
}
/**
* Save the settings for the current Interface.
- * @return bool true if successfull, false otherwise
+ * @return bool true if successful, false otherwise
*/
bool InterfaceSetupImp::saveSettings(){
// eh can't really do anything about it other then return. :-D
if(!interfaces->isInterfaceSet())
return true;
bool error = false;
// Loopback case
if(interfaces->getInterfaceMethod(error) == INTERFACES_LOOPBACK){
interfaces->setAuto(interface->getInterfaceName(), autoStart->isChecked());
return true;
}
if(!dhcpCheckBox->isChecked() && (ipAddressEdit->text().isEmpty() || subnetMaskEdit->text().isEmpty())){
QMessageBox::information(this, "Not Saved.", "Please fill in the IP address and\n subnet entries.", QMessageBox::Ok);
return false;
}
// DHCP
if(dhcpCheckBox->isChecked()) {
interfaces->setInterfaceMethod(INTERFACES_METHOD_DHCP);
interfaces->removeInterfaceOption("address");
interfaces->removeInterfaceOption("netmask");
interfaces->removeInterfaceOption("gateway");
interfaces->removeInterfaceOption("up "DNSSCRIPT" -a ");