diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-02-06 11:30:45 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-02-06 11:57:50 +0000 |
commit | 18a16b6bd818d9b3a5e5f3e870cdfad528aa46d4 (patch) | |
tree | b5ab0aec951692e61d9c84272460230c6b4e3d20 /vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx | |
parent | a9c63ef451ff88734b14b179691bf9d4a22a1e6b (diff) |
Related: rhbz#1061864 filtername is somehow NULL
Change-Id: I11930d8401ada43c7fce570131baf2e8a7067ecb
Diffstat (limited to 'vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx')
-rw-r--r-- | vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx index 372b8bf0c204..bdd24551b768 100644 --- a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx +++ b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx @@ -892,8 +892,11 @@ uno::Sequence<OUString> SAL_CALL SalGtkFilePicker::getSelectedFiles() throw( uno GtkFileFilter *filter = gtk_file_chooser_get_filter(GTK_FILE_CHOOSER(m_pDialog)); if (m_pPseudoFilter != filter) { - const gchar* filtername = gtk_file_filter_get_name( filter ); - sFilterName = OUString( filtername, strlen( filtername ), RTL_TEXTENCODING_UTF8 ); + const gchar* filtername = filter ? gtk_file_filter_get_name(filter) : NULL; + if (filtername) + sFilterName = OUString(filtername, strlen( filtername ), RTL_TEXTENCODING_UTF8); + else + sFilterName = OUString(); } else sFilterName = m_aInitialFilter; |