From c1decfddfde36ea5a19fc6e6cae77eedfa8dce21 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Minisini?= Date: Mon, 28 May 2012 08:08:36 +0000 Subject: [PATCH] [INTERPRETER] * BUG: Enumerating the Param class does not leak memory in some cases anymore. git-svn-id: svn://localhost/gambas/trunk@4788 867c0c6c-44f3-4631-809d-bfa615b0a4ec --- main/gbx/gbx_c_gambas.c | 3 +-- main/gbx/gbx_string.c | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/main/gbx/gbx_c_gambas.c b/main/gbx/gbx_c_gambas.c index 9e47b599d..d35916fcf 100644 --- a/main/gbx/gbx_c_gambas.c +++ b/main/gbx/gbx_c_gambas.c @@ -104,10 +104,9 @@ BEGIN_METHOD_VOID(Param_next) GB_StopEnum(); else { + VALUE_conv(&PP[*index], T_VARIANT); TEMP = PP[*index]; (*index)++; - GB_ReturnConvVariant(); - //VALUE_conv(&TEMP, T_VARIANT); } END_METHOD diff --git a/main/gbx/gbx_string.c b/main/gbx/gbx_string.c index 2e5709e51..4407bf6fa 100644 --- a/main/gbx/gbx_string.c +++ b/main/gbx/gbx_string.c @@ -412,14 +412,14 @@ char *STRING_extend(char *str, int new_len) { sstr = alloc_string(new_len); #ifdef DEBUG_ME - fprintf(stderr, "STRING_extend: NULL -> %p / %p\n", str, str->data); + fprintf(stderr, "STRING_extend: NULL -> %p / %p\n", sstr, sstr->data); #endif } else { sstr = realloc_string(STRING_from_ptr(str), new_len); #ifdef DEBUG_ME - fprintf(stderr, "STRING_extend: %p / %p -> %p / %p\n", STRING_from_ptr(*ptr), *ptr, str, str->data); + fprintf(stderr, "STRING_extend: %p / %p -> %p / %p\n", STRING_from_ptr(str), str, sstr, sstr->data); #endif }