summaryrefslogtreecommitdiff
path: root/src/project.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/project.c')
-rw-r--r--src/project.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/project.c b/src/project.c
index 8a8f803..cf50ef9 100644
--- a/src/project.c
+++ b/src/project.c
@@ -66,7 +66,7 @@ struct _GStudyProject
loaded_binary **binaries; /* Fichiers binaires associƩs */
size_t binaries_count; /* Nombre de ces fichiers */
- GMutex *mutex; /* Modification de la liste */
+ GMutex mutex; /* Modification de la liste */
};
@@ -131,8 +131,7 @@ static void g_study_project_class_init(GStudyProjectClass *klass)
static void g_study_project_init(GStudyProject *project)
{
- project->mutex = g_mutex_new();
- if (project->mutex == NULL) /* FIXME */;
+ g_mutex_init(&project->mutex);
}
@@ -419,7 +418,7 @@ size_t g_study_project_attach_binary(GStudyProject *project, GLoadedBinary *bina
/* Enregistrement dans le projet */
- g_mutex_lock(project->mutex);
+ g_mutex_lock(&project->mutex);
project->binaries = (loaded_binary **)realloc(project->binaries,
++project->binaries_count * sizeof(loaded_binary *));
@@ -428,7 +427,7 @@ size_t g_study_project_attach_binary(GStudyProject *project, GLoadedBinary *bina
project->binaries[result] = loaded;
- g_mutex_unlock(project->mutex);
+ g_mutex_unlock(&project->mutex);
update_project_area(project);