[tor-commits] [vidalia/alpha] Always return from ControlMethod::fromString

chiiph at torproject.org chiiph at torproject.org
Wed Mar 7 14:30:11 UTC 2012


commit 95b006a1b38600e20c364def9c80c5be92a9ac35
Author: Tomás Touceda <chiiph at torproject.org>
Date:   Wed Mar 7 11:29:10 2012 -0300

    Always return from ControlMethod::fromString
---
 changes/bug4065                  |    2 ++
 src/torcontrol/ControlMethod.cpp |    2 +-
 2 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/changes/bug4065 b/changes/bug4065
new file mode 100644
index 0000000..0dbced5
--- /dev/null
+++ b/changes/bug4065
@@ -0,0 +1,2 @@
+  o Improve a method that didn't returned the specified type if
+    another control method was selected. Fixes bug 4065.
\ No newline at end of file
diff --git a/src/torcontrol/ControlMethod.cpp b/src/torcontrol/ControlMethod.cpp
index dbfd948..905bf7c 100644
--- a/src/torcontrol/ControlMethod.cpp
+++ b/src/torcontrol/ControlMethod.cpp
@@ -37,6 +37,6 @@ ControlMethod::fromString(QString method)
 {
   if(method == QString("ControlPort"))
     return ControlMethod::Port;
-  else if(method == QString("ControlSocket"))
+  else// if(method == QString("ControlSocket"))
     return ControlMethod::Socket;
 }



More information about the tor-commits mailing list