diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2018-12-12 17:07:05 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2018-12-12 17:07:05 (GMT) |
commit | c806bc75910c129c6d78115cfdc571316e060412 (patch) | |
tree | 3752138befa5508fe43ea3410237c5edb1163cbf /src/core | |
parent | d5b598b14fd4c50847ce536692ded258ba1720ca (diff) |
Reorganized the global variables access in the Python bindings.
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/global.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/core/global.c b/src/core/global.c index 8736b30..3777fd9 100644 --- a/src/core/global.c +++ b/src/core/global.c @@ -261,9 +261,8 @@ void set_current_project(GStudyProject *project) GStudyProject *get_current_project(void) { - assert(_project != NULL); - - g_object_ref(G_OBJECT(_project)); + if (_project != NULL) + g_object_ref(G_OBJECT(_project)); return _project; |