summaryrefslogtreecommitdiff
path: root/sfx2/source/control/request.cxx
diff options
context:
space:
mode:
authorArmin Le Grand (allotropia) <armin.le.grand.extern@allotropia.de>2024-04-08 11:03:00 +0200
committerArmin Le Grand <Armin.Le.Grand@me.com>2024-04-08 17:16:49 +0200
commitb4626d809b50f1d5c1aa8a9644dd3913f5b15503 (patch)
treea55e573f581b464b8dc0fd146833452dacf149f3 /sfx2/source/control/request.cxx
parent2533960315607bf3e86ad014d2daa4bfa7e3fa59 (diff)
tdf#159719 reset SfxPoolItemHolder when Pool changes
Change-Id: Ic2724c6e03acaa8cfc74dc2aadfac6b13d8561c0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165883 Tested-by: Jenkins Tested-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org> Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org> Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
Diffstat (limited to 'sfx2/source/control/request.cxx')
-rw-r--r--sfx2/source/control/request.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/sfx2/source/control/request.cxx b/sfx2/source/control/request.cxx
index 9406ce8b9fd3..e58475c325f1 100644
--- a/sfx2/source/control/request.cxx
+++ b/sfx2/source/control/request.cxx
@@ -109,7 +109,12 @@ void SfxRequest_Impl::SetPool( SfxItemPool *pNewPool )
{
if ( pPool )
EndListening( pPool->BC() );
+
+ // tdf#159719 reset SfxPoolItemHolder
+ aRetVal = SfxPoolItemHolder();
+
pPool = pNewPool;
+
if ( pNewPool )
StartListening( pNewPool->BC() );
}