diff options
author | Colin Walters <walters@verbum.org> | 2010-09-02 17:40:54 -0400 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2010-09-02 17:43:23 -0400 |
commit | 4a01ca43c976ba09c1647cbc56918f3b3e917ff4 (patch) | |
tree | d2861f6a9e20e7cc77bfba43ac6dbc2fd4eee68d /girepository/girepository.c | |
parent | 9c7ced784f00b2953a118cd9a695ba5beac69638 (diff) | |
download | gobject-introspection-4a01ca43c976ba09c1647cbc56918f3b3e917ff4.tar.gz |
girepository: Call init_globals()
This fixes the search path initialization if g_irepository_require
is called first thing.
Diffstat (limited to 'girepository/girepository.c')
-rw-r--r-- | girepository/girepository.c | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/girepository/girepository.c b/girepository/girepository.c index db4fdc97..a8c661ab 100644 --- a/girepository/girepository.c +++ b/girepository/girepository.c @@ -168,19 +168,21 @@ g_irepository_get_search_path (void) return search_path; } -static -GSList * +static GSList * build_search_path_with_overrides (void) { - GSList *result; - if (override_search_path != NULL) - { - result = g_slist_copy (override_search_path); - g_slist_last (result)->next = g_slist_copy (search_path); - } - else - result = g_slist_copy (search_path); - return result; + GSList *result; + + init_globals (); + + if (override_search_path != NULL) + { + result = g_slist_copy (override_search_path); + g_slist_last (result)->next = g_slist_copy (search_path); + } + else + result = g_slist_copy (search_path); + return result; } static char * |