From 7b530132fab2934619e21cdbf110e7f8e654e89d Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 29 Apr 2013 23:17:43 +0200 Subject: [PATCH] DeviceDescriptor: check cancellation state in OpenOnPort() Abort the whole operation if the user has pressed "cancel". --- src/Device/Descriptor.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Device/Descriptor.cpp b/src/Device/Descriptor.cpp index 66c511095..27c474d7e 100644 --- a/src/Device/Descriptor.cpp +++ b/src/Device/Descriptor.cpp @@ -225,7 +225,7 @@ DeviceDescriptor::OpenOnPort(Port &_port, OperationEnvironment &env) port->StartRxThread(); EnableNMEA(env); - return true; + return !env.IsCancelled(); } bool -- 2.11.4.GIT