Diff between 534a5d3d9525945b4cf9a146ec3d66e606688f90 and c8808e3acd55fea9f667efaf9f51b6c3ef094713

Changed Files

File Additions Deletions Status
profiles/network/connection.c +4 -2 modified

Full Patch

diff --git a/profiles/network/connection.c b/profiles/network/connection.c
index 4b30aa3..671478c 100644
--- a/profiles/network/connection.c
+++ b/profiles/network/connection.c
@@ -349,7 +349,7 @@ static gboolean bnep_conn_req_to(gpointer user_data)
 		error("Too many bnep connection attempts");
 	} else {
 		error("bnep connection setup TO, retrying...");
-		if (!bnep_send_conn_req(nc))
+		if (bnep_send_conn_req(nc) == 0)
 			return TRUE;
 	}
 
@@ -363,7 +363,9 @@ static int bnep_connect(struct network_conn *nc)
 	int err;
 
 	nc->attempt_cnt = 0;
-	if ((err = bnep_send_conn_req(nc)))
+
+	err = bnep_send_conn_req(nc);
+	if (err < 0)
 		return err;
 
 	nc->timeout_source = g_timeout_add_seconds(CON_SETUP_TO,