summaryrefslogtreecommitdiff
path: root/gtk/gtksearchengine.c
diff options
context:
space:
mode:
authorEmmanuele Bassi <ebassi@gnome.org>2007-05-11 14:08:57 +0000
committerEmmanuele Bassi <ebassi@src.gnome.org>2007-05-11 14:08:57 +0000
commit3768e2be79bd3b5ffb8d231888204af31ca3b2fe (patch)
tree5238c8837d0e60ebcd8c1d5261e2dfb225dd1122 /gtk/gtksearchengine.c
parent75092d295b554b5e39c41b839810854bed1c5a9e (diff)
downloadgtk+-3768e2be79bd3b5ffb8d231888204af31ca3b2fe.tar.gz
Fall back to GtkSearchEngineSimple only if gthread has already been
2007-05-11 Emmanuele Bassi <ebassi@gnome.org> * gtk/gtksearchengine.c (_gtk_search_engine_new): Fall back to GtkSearchEngineSimple only if gthread has already been initialiased; otherwise, disable search support in the file chooser widget. (#435847) svn path=/trunk/; revision=17819
Diffstat (limited to 'gtk/gtksearchengine.c')
-rw-r--r--gtk/gtksearchengine.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/gtk/gtksearchengine.c b/gtk/gtksearchengine.c
index 196e944d8e..85145d02e6 100644
--- a/gtk/gtksearchengine.c
+++ b/gtk/gtksearchengine.c
@@ -104,7 +104,7 @@ _gtk_search_engine_init (GtkSearchEngine *engine)
GtkSearchEngine *
_gtk_search_engine_new (void)
{
- GtkSearchEngine *engine;
+ GtkSearchEngine *engine = NULL;
#ifdef HAVE_TRACKER
engine = _gtk_search_engine_tracker_new ();
@@ -118,7 +118,9 @@ _gtk_search_engine_new (void)
return engine;
#endif
- engine = _gtk_search_engine_simple_new ();
+ if (g_thread_supported ())
+ engine = _gtk_search_engine_simple_new ();
+
return engine;
}