summaryrefslogtreecommitdiffstats
path: root/voip/java/com/android
diff options
context:
space:
mode:
authorHung-ying Tyan <tyanh@google.com>2010-10-05 13:00:13 +0800
committerHung-ying Tyan <tyanh@google.com>2010-10-05 13:30:28 +0800
commitc6548fd9eda7b58f5a2e2a9c01e3c7cafd42fafb (patch)
tree3d9751a342a382f6187ddda8031f6633f4e5b030 /voip/java/com/android
parent368733b204805cfa716897b09153350a70dca3f3 (diff)
downloadframeworks_base-c6548fd9eda7b58f5a2e2a9c01e3c7cafd42fafb.zip
frameworks_base-c6548fd9eda7b58f5a2e2a9c01e3c7cafd42fafb.tar.gz
frameworks_base-c6548fd9eda7b58f5a2e2a9c01e3c7cafd42fafb.tar.bz2
SIP: add SERVER_UNREACHABLE error code.
Let SipSession return it when UnknownHostException is caught. Add DisconnectCause.SERVER_UNREACHABLE in Connection and have SipPhone report it when receiving SERVER_UNREACHABLE from SipSession. http://b/issue?id=3061691 Change-Id: I944328ba3ee30c0a9386e89b5c4696d4d9bde000
Diffstat (limited to 'voip/java/com/android')
-rw-r--r--voip/java/com/android/server/sip/SipSessionGroup.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/voip/java/com/android/server/sip/SipSessionGroup.java b/voip/java/com/android/server/sip/SipSessionGroup.java
index bc377cf..37fffa8 100644
--- a/voip/java/com/android/server/sip/SipSessionGroup.java
+++ b/voip/java/com/android/server/sip/SipSessionGroup.java
@@ -480,7 +480,7 @@ class SipSessionGroup implements SipListener {
public void run() {
try {
processCommand(command);
- } catch (SipException e) {
+ } catch (Throwable e) {
Log.w(TAG, "command error: " + command, e);
onError(e);
}
@@ -1218,7 +1218,7 @@ class SipSessionGroup implements SipListener {
private int getErrorCode(Throwable exception) {
String message = exception.getMessage();
if (exception instanceof UnknownHostException) {
- return SipErrorCode.INVALID_REMOTE_URI;
+ return SipErrorCode.SERVER_UNREACHABLE;
} else if (exception instanceof IOException) {
return SipErrorCode.SOCKET_ERROR;
} else {