Diff between 0e260e458c155654524ec76163ece3f65a8d4f9f and 17c8980ad31c6c77c35124cf8d9e3a3c3c8c732a

Changed Files

File Additions Deletions Status
client/gatt.c +8 -2 modified

Full Patch

diff --git a/client/gatt.c b/client/gatt.c
index b83bea7..b640b6e 100644
--- a/client/gatt.c
+++ b/client/gatt.c
@@ -679,11 +679,17 @@ static bool pipe_hup(struct io *io, void *user_data)
 	struct chrc *chrc = user_data;
 
 	if (chrc) {
-		bt_shell_printf("Attribute %s Write pipe closed\n", chrc->path);
-		if (chrc->write_io) {
+		bt_shell_printf("Attribute %s %s pipe closed\n", chrc->path,
+				io == chrc->write_io ? "Write" : "Notify");
+
+		if (io == chrc->write_io) {
 			io_destroy(chrc->write_io);
 			chrc->write_io = NULL;
+		} else {
+			io_destroy(chrc->notify_io);
+			chrc->notify_io = NULL;
 		}
+
 		return false;
 	}