Browse Source

Don't crash when incorrectly appending the port number to an rTorrent IP/hostname configuration. Fixes #480

pull/506/head
Eric Kok 6 years ago
parent
commit
a0995a73a3
  1. 3
      app/src/main/java/org/transdroid/daemon/Rtorrent/RtorrentAdapter.java

3
app/src/main/java/org/transdroid/daemon/Rtorrent/RtorrentAdapter.java

@ -339,6 +339,9 @@ public class RtorrentAdapter implements IDaemonAdapter { @@ -339,6 +339,9 @@ public class RtorrentAdapter implements IDaemonAdapter {
log.d(LOG_NAME, "Calling " + serverMethod + " with params [" +
(params.length() > 100 ? params.substring(0, 100) + "..." : params) + " ]");
return rpcclient.call(serverMethod, arguments);
} catch (IllegalArgumentException e) {
log.d(LOG_NAME, "Using " + buildWebUIUrl() + ": " + e.toString());
throw new DaemonException(ExceptionType.ConnectionError, "Error making call to " + serverMethod);
} catch (XMLRPCException e) {
log.d(LOG_NAME, e.toString());
if (e.getCause() instanceof UnauthorizdException) {

Loading…
Cancel
Save