Skip to content

Commit ebd8dfc

Browse files
kcudnikyxieca
authored andcommitted
Move stop notifications thread after remove switch (sonic-net#401)
* Move stop notifications trhead after remove switch * Remove stop notifications processing thread from pre shutdown
1 parent bb3ff64 commit ebd8dfc

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

syncd/syncd.cpp

+3-4
Original file line numberDiff line numberDiff line change
@@ -3681,7 +3681,6 @@ int syncd_main(int argc, char **argv)
36813681
SWSS_LOG_TIMER("warm pre-shutdown");
36823682

36833683
FlexCounter::removeAllCounters();
3684-
stopNotificationsProcessingThread();
36853684

36863685
sai_attribute_t attr;
36873686

@@ -3814,14 +3813,14 @@ int syncd_main(int argc, char **argv)
38143813

38153814
FlexCounter::removeAllCounters();
38163815

3817-
// Stop notification thread before removing switch
3818-
stopNotificationsProcessingThread();
3819-
38203816
{
38213817
SWSS_LOG_TIMER("remove switch");
38223818
status = sai_switch_api->remove_switch(gSwitchId);
38233819
}
38243820

3821+
// Stop notification thread after removing switch
3822+
stopNotificationsProcessingThread();
3823+
38253824
if (status != SAI_STATUS_SUCCESS)
38263825
{
38273826
SWSS_LOG_NOTICE("Can't delete a switch. gSwitchId=0x%lx status=%s", gSwitchId,

0 commit comments

Comments
 (0)