diff options
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/toolbars/fontworkbar.cxx | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/svx/source/toolbars/fontworkbar.cxx b/svx/source/toolbars/fontworkbar.cxx index 90b05316fdc0..290c1f746fe4 100644 --- a/svx/source/toolbars/fontworkbar.cxx +++ b/svx/source/toolbars/fontworkbar.cxx @@ -340,7 +340,10 @@ static void GetGeometryForCustomShape( SdrCustomShapeGeometryItem& rGeometryItem if ( GalleryExplorer::GetSdrObj( GALLERY_THEME_POWERPOINT, i, &aFormModel ) ) { - const SdrObject* pSourceObj = aFormModel.GetPage( 0 )->GetObj( 0 ); + const SdrObject* pSourceObj = nullptr; + if (aFormModel.GetPageCount() > 0) + pSourceObj = aFormModel.GetPage( 0 )->GetObj( 0 ); + SAL_WARN_IF(!pSourceObj, "svx.form", "No content in gallery custom shape '" << rCustomShape << "'" ); if( pSourceObj ) { PropertyValue aPropVal_; |