summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/bfd.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/bfd.c b/lib/bfd.c
index 29b8d85d8d..ec135245d7 100644
--- a/lib/bfd.c
+++ b/lib/bfd.c
@@ -508,13 +508,13 @@ static void _bfd_sess_send(struct thread *t)
static void _bfd_sess_remove(struct bfd_session_params *bsp)
{
+ /* Cancel any pending installation request. */
+ THREAD_OFF(bsp->installev);
+
/* Not installed, nothing to do. */
if (!bsp->installed)
return;
- /* Cancel any pending installation request. */
- THREAD_OFF(bsp->installev);
-
/* Send request to remove any session. */
bsp->lastev = BSE_UNINSTALL;
thread_execute(bsglobal.tm, _bfd_sess_send, bsp, 0);