diff options
author | Herbert Duerr [hdu] <duerr@sun.com> | 2010-03-17 10:38:47 +0100 |
---|---|---|
committer | Herbert Duerr [hdu] <duerr@sun.com> | 2010-03-17 10:38:47 +0100 |
commit | 9fd504900c9041079effc0a7f7a370089bf4a770 (patch) | |
tree | 4db59d0fb6150b22383459453168f7c6ebc879d3 /vcl/unx/source/gdi/salgdi3.cxx | |
parent | baed90063d7108a5718881dd780e4aa32b1057a0 (diff) |
#i110165# prevent NULL option for cairo_ft_font_options_substitute()
Diffstat (limited to 'vcl/unx/source/gdi/salgdi3.cxx')
-rw-r--r-- | vcl/unx/source/gdi/salgdi3.cxx | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/vcl/unx/source/gdi/salgdi3.cxx b/vcl/unx/source/gdi/salgdi3.cxx index 0c1fcd7c77bd..d60f575ad674 100644 --- a/vcl/unx/source/gdi/salgdi3.cxx +++ b/vcl/unx/source/gdi/salgdi3.cxx @@ -1633,11 +1633,13 @@ void X11SalGraphics::GetDevFontSubstList( OutputDevice* ) void cairosubcallback( void* pPattern ) { CairoWrapper& rCairo = CairoWrapper::get(); - if( rCairo.isValid() ) - { + if( !rCairo.isValid() ) + return; const StyleSettings& rStyleSettings = Application::GetSettings().GetStyleSettings(); - rCairo.ft_font_options_substitute( rStyleSettings.GetCairoFontOptions(), pPattern); - } + const void* pFontOptions = rStyleSettings.GetCairoFontOptions(); + if( !pFontOptions ) + return; + rCairo.ft_font_options_substitute( pFontOptions, pPattern ); } bool GetFCFontOptions( const ImplFontAttributes& rFontAttributes, int nSize, |