Diff between ec8988232beee52aaa236c7e1de539b5bd53379f and 4d00f270b9ff032e17148ebeb66ca60e641de1d2

Changed Files

File Additions Deletions Status
android/gatt.c +2 -18 modified

Full Patch

diff --git a/android/gatt.c b/android/gatt.c
index e339789..ec4395d 100644
--- a/android/gatt.c
+++ b/android/gatt.c
@@ -864,25 +864,9 @@ static gboolean disconnected_cb(GIOChannel *io, GIOCondition cond,
 
 	sock = g_io_channel_unix_get_fd(io);
 	len = sizeof(err);
-	if (getsockopt(sock, SOL_SOCKET, SO_ERROR, &err, &len) < 0)
-		goto done;
-
-	DBG("%s (%d)", strerror(err), err);
-
-	/* Keep scanning/re-connection active if disconnection reason
-	 * is connection timeout, remote user terminated connection or local
-	 * initiated disconnection.
-	 */
-	if (err == ETIMEDOUT || err == ECONNRESET || err == ECONNABORTED) {
-		if (!queue_push_tail(conn_wait_queue, dev)) {
-			error("gatt: Cannot push data");
-		} else {
-			bt_le_discovery_start(le_device_found_handler);
-			return FALSE;
-		}
-	}
+	if (!getsockopt(sock, SOL_SOCKET, SO_ERROR, &err, &len))
+		DBG("%s (%d)", strerror(err), err);
 
-done:
 	connection_cleanup(dev);
 
 	queue_foreach(dev->clients, client_disconnect_notify, dev);