Diff between d24560cf46154b7364eeea8d9b3f77e50b6ee63a and 70a609bb3a7401b56377de77586e09a56d631468

Changed Files

File Additions Deletions Status
profiles/sap/server.c +6 -2 modified

Full Patch

diff --git a/profiles/sap/server.c b/profiles/sap/server.c
index 530f994..bb37c18 100644
--- a/profiles/sap/server.c
+++ b/profiles/sap/server.c
@@ -1295,11 +1295,15 @@ static gboolean server_property_get_connected(
 	struct sap_connection *conn = server->conn;
 	dbus_bool_t connected;
 
-	if (!conn)
-		return FALSE;
+	if (!conn) {
+		connected = FALSE;
+		goto append;
+	}
 
 	connected = (conn->state == SAP_STATE_CONNECTED ||
 				conn->state == SAP_STATE_GRACEFUL_DISCONNECT);
+
+append:
 	dbus_message_iter_append_basic(iter, DBUS_TYPE_BOOLEAN, &connected);
 
 	return TRUE;