Resolves: fdo#79131 crash in EnhancedCustomShapeTypeNames::Get

Change-Id: Ib21a4a1574119120f09d4ecac73b93a0f2f6739f
(cherry picked from commit 65277f994ae25d930c15aebba0ed19f8de0abba1)
Reviewed-on: https://gerrit.libreoffice.org/11704
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>