diff options
Diffstat (limited to 'src/arch')
-rw-r--r-- | src/arch/processor.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/arch/processor.c b/src/arch/processor.c index 4d7bacc..05e3206 100644 --- a/src/arch/processor.c +++ b/src/arch/processor.c @@ -187,6 +187,11 @@ static void g_arch_processor_init(GArchProcessor *proc) static void g_arch_processor_dispose(GArchProcessor *proc) { + size_t i; /* Boucle de parcours */ + + for (i = 0; i < proc->instr_count; i++) + g_clear_object(&proc->instructions[i]); + g_mutex_clear(&proc->mutex); g_mutex_clear(&proc->error_mutex); @@ -212,6 +217,9 @@ static void g_arch_processor_finalize(GArchProcessor *proc) { size_t i; /* Boucle de parcours */ + if (proc->instructions != NULL) + free(proc->instructions); + if (proc->errors != NULL) { for (i = 0; i < proc->error_count; i++) |