From 3c08f447152c9ef0e973efab36cc69cf63059038 Mon Sep 17 00:00:00 2001 From: Johan Hedberg Date: Wed, 15 Jan 2014 14:38:04 +0200 Subject: [PATCH] emulator/bthost: Fix requesting encryption if authentication failed --- emulator/bthost.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/emulator/bthost.c b/emulator/bthost.c index 0dd7c67d8..fc1d81078 100644 --- a/emulator/bthost.c +++ b/emulator/bthost.c @@ -691,6 +691,9 @@ static void evt_auth_complete(struct bthost *bthost, const void *data, if (len < sizeof(*ev)) return; + if (ev->status) + return; + cp.handle = ev->handle; cp.encr_mode = 0x01; -- 2.47.3