This commit is contained in:
iNPUTmice 2014-10-21 19:43:34 +02:00
parent a56ee63a3e
commit 3821a72644
3 changed files with 6 additions and 6 deletions

View File

@ -150,8 +150,8 @@ public class JingleConnection implements Downloadable {
return this.sessionId;
}
public String getAccountJid() {
return this.account.getFullJid();
public Account getAccount() {
return this.account;
}
public String getCounterPart() {

View File

@ -36,7 +36,7 @@ public class JingleConnectionManager extends AbstractConnectionManager {
connections.add(connection);
} else {
for (JingleConnection connection : connections) {
if (connection.getAccountJid().equals(account.getFullJid())
if (connection.getAccount() == account
&& connection.getSessionId().equals(
packet.getSessionId())
&& connection.getCounterPart().equals(packet.getFrom())) {
@ -136,7 +136,7 @@ public class JingleConnectionManager extends AbstractConnectionManager {
}
if (sid != null) {
for (JingleConnection connection : connections) {
if (connection.hasTransportId(sid)) {
if (connection.getAccount() == account && connection.hasTransportId(sid)) {
JingleTransport transport = connection.getTransport();
if (transport instanceof JingleInbandTransport) {
JingleInbandTransport inbandTransport = (JingleInbandTransport) transport;

View File

@ -30,11 +30,11 @@ public class JingleSocks5Transport extends JingleTransport {
StringBuilder destBuilder = new StringBuilder();
destBuilder.append(jingleConnection.getSessionId());
if (candidate.isOurs()) {
destBuilder.append(jingleConnection.getAccountJid());
destBuilder.append(jingleConnection.getAccount().getFullJid());
destBuilder.append(jingleConnection.getCounterPart());
} else {
destBuilder.append(jingleConnection.getCounterPart());
destBuilder.append(jingleConnection.getAccountJid());
destBuilder.append(jingleConnection.getAccount().getFullJid());
}
mDigest.reset();
this.destination = CryptoHelper.bytesToHex(mDigest