OSDN Git Service
(root)
/
android-x86
/
frameworks-base.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
616dfe3
)
Bluetooth stopped working in master - "bad file descriptor"
author
Zhihai Xu
<zhihaixu@google.com>
Wed, 24 Jul 2013 22:09:45 +0000
(15:09 -0700)
committer
Zhihai Xu
<zhihaixu@google.com>
Wed, 24 Jul 2013 22:09:45 +0000
(15:09 -0700)
ignore IllegalArgumentException in BluetoothSocket.close().
bug:
9960585
Change-Id: I301aa388b738dcb92b643fdd96b5c9cb6f8b3efe
core/java/android/bluetooth/BluetoothSocket.java
patch
|
blob
|
history
diff --git
a/core/java/android/bluetooth/BluetoothSocket.java
b/core/java/android/bluetooth/BluetoothSocket.java
index
d10eaea
..
5c534a1
100644
(file)
--- a/
core/java/android/bluetooth/BluetoothSocket.java
+++ b/
core/java/android/bluetooth/BluetoothSocket.java
@@
-461,8
+461,13
@@
public final class BluetoothSocket implements Closeable {
mSocket.close();
mSocket = null;
}
- if(mPfd != null)
- mPfd.detachFd();
+ if(mPfd != null) {
+ try {
+ mPfd.detachFd();
+ } catch (IllegalArgumentException e) {
+ Log.w(TAG, "ignore IllegalArgumentException");
+ }
+ }
}
}
}