[anjuta] dir-project: check for NULL groups in dir_project_is_loaded()
- From: Carl-Anton Ingmarsson <carlantoni src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [anjuta] dir-project: check for NULL groups in dir_project_is_loaded()
- Date: Wed, 3 Apr 2013 22:14:49 +0000 (UTC)
commit ea132dd6915a0484a4790aa1e28a07f2b5201310
Author: Carl-Anton Ingmarsson <ca ingmarsson gmail com>
Date: Thu Apr 4 00:12:09 2013 +0200
dir-project: check for NULL groups in dir_project_is_loaded()
project->groups will be NULL if dir_project_load_root() has not been called yet.
plugins/dir-project/dir-project.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/plugins/dir-project/dir-project.c b/plugins/dir-project/dir-project.c
index 8f3a3ad..95a95ac 100644
--- a/plugins/dir-project/dir-project.c
+++ b/plugins/dir-project/dir-project.c
@@ -906,6 +906,9 @@ find_not_loaded_node (gpointer key, gpointer value, gpointer user_data)
static gboolean
dir_project_is_loaded (DirProject *project)
{
+ if (project->groups == NULL)
+ return FALSE;
+
return g_hash_table_find (project->groups, find_not_loaded_node, NULL) == NULL;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]