[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[vidalia-svn] r2211: Don't let people save an empty string for a Tor executable. (in trunk: . src/vidalia/config)
Author: edmanm
Date: 2007-12-11 22:28:18 -0500 (Tue, 11 Dec 2007)
New Revision: 2211
Modified:
trunk/
trunk/src/vidalia/config/generalpage.cpp
Log:
r2293@lysithea: edmanm | 2007-12-11 22:14:11 -0500
Don't let people save an empty string for a Tor executable.
Property changes on: trunk
___________________________________________________________________
svk:merge ticket from /local/vidalia/trunk [r2293] on 0108964c-5b0b-4c9e-969f-e2288315d100
Modified: trunk/src/vidalia/config/generalpage.cpp
===================================================================
--- trunk/src/vidalia/config/generalpage.cpp 2007-12-11 21:48:59 UTC (rev 2210)
+++ trunk/src/vidalia/config/generalpage.cpp 2007-12-12 03:28:18 UTC (rev 2211)
@@ -1,7 +1,7 @@
/****************************************************************
* Vidalia is distributed under the following license:
*
- * Copyright (C) 2006, Matt Edman, Justin Hipple
+ * Copyright (C) 2006-2007, Matt Edman, Justin Hipple
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
@@ -81,8 +81,12 @@
bool
GeneralPage::save(QString &errmsg)
{
- Q_UNUSED(errmsg);
- _torSettings->setExecutable(ui.lineTorExecutable->text());
+ QString torExecutable = ui.lineTorExecutable->text();
+ if (torExecutable.isEmpty()) {
+ errmsg = tr("You must specify the name of your Tor executable.");
+ return false;
+ }
+ _torSettings->setExecutable(torExecutable);
_vidaliaSettings->setRunTorAtStart(ui.chkRunTor->isChecked());
_vidaliaSettings->setRunVidaliaOnBoot(ui.chkRunWithSys->isChecked());
return true;