From 18f9abffadec8337561bef16b006e2968f224538 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zdib=C3=A1k=20Zolt=C3=A1n?= Date: Sat, 10 Nov 2018 20:04:43 +0100 Subject: [PATCH] cppCheck narrowed variableScope rEntry Change-Id: I04b0b0dc85afdceead9766d8a45e21055074d5fc Reviewed-on: https://gerrit.libreoffice.org/63248 Tested-by: Jenkins Reviewed-by: Markus Mohrhard --- cppuhelper/source/component_context.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cppuhelper/source/component_context.cxx b/cppuhelper/source/component_context.cxx index b64d8b624849..b2c4cf4d5112 100644 --- a/cppuhelper/source/component_context.cxx +++ b/cppuhelper/source/component_context.cxx @@ -400,12 +400,12 @@ void ComponentContext::disposing() t_map::iterator const iEnd( m_map.end() ); for ( ; iPos != iEnd; ++iPos ) { - ContextEntry& rEntry = iPos->second; - // service manager disposed separately if (!m_xSMgr.is() || !iPos->first.startsWith( SMGR_SINGLETON )) { + ContextEntry& rEntry = iPos->second; + if (rEntry.lateInit) { // late init