Skip to content

Commit ad83e50

Browse files
Bundle Start after Framework Stop race fix (CppMicroServices#990) (CppMicroServices#1189)
Co-authored-by: tcormackMW <113473781+tcormackMW@users.noreply.github.com>
1 parent 75cfe64 commit ad83e50

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

framework/src/util/FrameworkPrivate.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,6 @@ namespace cppmicroservices
160160
{
161161
auto l = Lock();
162162
US_UNUSED(l);
163-
auto writerLock = coreCtx->SetFrameworkStateAndBlockUntilComplete(true);
164163
bool wasActive = false;
165164
switch (static_cast<Bundle::State>(state.load()))
166165
{
@@ -305,7 +304,10 @@ namespace cppmicroservices
305304
{
306305
StopAllBundles();
307306
}
308-
coreCtx->Uninit0();
307+
{
308+
auto lock = coreCtx->SetFrameworkStateAndBlockUntilComplete(true);
309+
coreCtx->Uninit0();
310+
}
309311
{
310312
auto l = Lock();
311313
US_UNUSED(l);

0 commit comments

Comments
 (0)