diff src/audacious/tuple_compiler.c @ 3818:10a72af488d9 trunk

Fix a stupid bug in memory reallocation of the evaluator.
author Matti Hamalainen <ccr@tnsp.org>
date Sat, 20 Oct 2007 06:05:53 +0300
parents 5ea2431c12bf
children c597262d6d50
line wrap: on
line diff
--- a/src/audacious/tuple_compiler.c	Sat Oct 20 06:05:04 2007 +0300
+++ b/src/audacious/tuple_compiler.c	Sat Oct 20 06:05:53 2007 +0300
@@ -733,7 +733,7 @@
       *reslen += strlen(str);
       if (*res) {
         if (*reslen >= *resmax) {
-          *resmax += MIN_ALLOC_BUF;
+          *resmax += *reslen + MIN_ALLOC_BUF;
           *res = g_realloc(*res, *resmax);
         }