From 726e08d71669378292488399285df91acac2cf89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?IOhannes=20m=20zm=C3=B6lnig?= Date: Wed, 31 Aug 2005 09:57:51 +0000 Subject: fixed bug that wrongly guessed the size of the new symbol (lead to crashes) svn path=/trunk/externals/zexy/; revision=3466 --- src/list2symbol.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/list2symbol.c b/src/list2symbol.c index 34b3f5b..1c77c34 100644 --- a/src/list2symbol.c +++ b/src/list2symbol.c @@ -58,12 +58,15 @@ static void list2symbol_bang(t_list2symbol *x) while(i--){ char buffer[MAXPDSTRING]; + int len=0; if(A_SYMBOL==argv->a_type){ - length+=strlen(argv->a_w.w_symbol->s_name); + len=strlen(argv->a_w.w_symbol->s_name); } else { - atom_string(argv++, buffer, MAXPDSTRING); - length+=strlen(buffer); + atom_string(argv, buffer, MAXPDSTRING); + len=strlen(buffer); } + length+=len; + argv++; } if (length<=0){ -- cgit v1.2.1