[PATCH 1/2] serial: fix DBus message reply

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: "Gustavo F. Padovan" <padovan@xxxxxxxxxxxxxx>

If reply is NULL we have a crash.
---
 serial/port.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/serial/port.c b/serial/port.c
index d011084..2cdead4 100644
--- a/serial/port.c
+++ b/serial/port.c
@@ -369,7 +369,7 @@ static void get_record_cb(sdp_list_t *recs, int err, gpointer user_data)
 	GError *gerr = NULL;
 
 	if (!port->listener_id) {
-		reply = NULL;
+		reply = btd_error_failed(port->msg, "No listening application");
 		goto failed;
 	}
 
-- 
1.7.6.2

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux