aboutsummaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorSergiusz Bazanski <q3k@q3k.org>2018-08-01 11:53:52 +0100
committerSergiusz Bazanski <q3k@q3k.org>2018-08-01 11:53:52 +0100
commitf041f0189597d10fee7e2ecb8bfdb3324dea3a43 (patch)
treeed82099143b95ff6d538b90c576fa68c241c58ba /common
parent1996f8c2d77b70332312353e45de9ef0f12b4c61 (diff)
downloadnextpnr-f041f0189597d10fee7e2ecb8bfdb3324dea3a43.tar.gz
nextpnr-f041f0189597d10fee7e2ecb8bfdb3324dea3a43.tar.bz2
nextpnr-f041f0189597d10fee7e2ecb8bfdb3324dea3a43.zip
router: release lock on failure to unblock UI
Diffstat (limited to 'common')
-rw-r--r--common/router1.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/common/router1.cc b/common/router1.cc
index d35a7621..46be444e 100644
--- a/common/router1.cc
+++ b/common/router1.cc
@@ -588,6 +588,7 @@ bool router1(Context *ctx)
if (jobQueue.empty()) {
log_info("found no unrouted source-sink pairs. no routing necessary.\n");
+ ctx->unlock();
return true;
}
@@ -602,6 +603,7 @@ bool router1(Context *ctx)
#ifndef NDEBUG
ctx->check();
#endif
+ ctx->unlock();
return false;
}
@@ -807,6 +809,7 @@ bool router1(Context *ctx)
}
log_info("Checksum: 0x%08x\n", ctx->checksum());
ctx->check();
+ ctx->unlock();
return false;
}
#endif