Commit ab1ff7dd authored by Tomas Touceda's avatar Tomas Touceda
Browse files

Merge branch 'bug4048_unlinkportconf_backport'

parents b3775aa1 9d475bcb
Loading
Loading
Loading
Loading

changes/bug4048

0 → 100644
+2 −0
Original line number Diff line number Diff line
  o Attempt to remove port.conf file before using it to avoid a race
    condition between tor and Vidalia. Fixes bug 4048.
 No newline at end of file
+5 −1
Original line number Diff line number Diff line
@@ -1069,9 +1069,13 @@ MainWindow::start()
  
  if(settings.getControlMethod() == ControlMethod::Port) {
    if(settings.autoControlPort()) {
      QString portconf = QString("%1/port.conf").arg(expDataDirectory);
      if(!QFile::remove(portconf))
        vWarn(QString("Unable to remove %s, may be it didn't existed.").arg(portconf));

      args << "ControlPort" << "auto";
      args << "SocksPort" << "auto";
      args << "ControlPortWriteToFile" << QString("%1/port.conf").arg(expDataDirectory);
      args << "ControlPortWriteToFile" << portconf;
    } else {
      /* Add the intended control port value */
      quint16 controlPort = settings.getControlPort();