bugfix
authorMatthias Braun <matze@braunis.de>
Tue, 4 May 2010 13:15:10 +0000 (13:15 +0000)
committerMatthias Braun <matze@braunis.de>
Tue, 4 May 2010 13:15:10 +0000 (13:15 +0000)
[r27481]

ir/obstack/obstack_printf.c

index a8b5a98..9d92092 100644 (file)
@@ -16,7 +16,7 @@ int obstack_vprintf(struct obstack *obst, const char *fmt, va_list ap)
        int     len;
 
        for (;;) {
-               len = vsnprintf(buffer, sizeof(buffer), fmt, ap);
+               len = vsnprintf(buffer, size, fmt, ap);
 
                /* snprintf should return -1 only in the error case, but older glibcs
                 * and probably other systems are buggy in this respect and return -1 if