changeset 1110:fd631764eaac

Revert removal of "+2" from Outbuffer::reserve function for x64. Unless somone can fix this properly, then the "+2" must stay in or tango won't build.
author Kelly Wilson <wilsonk cpsc.ucalgary.ca>
date Thu, 12 Mar 2009 17:10:24 -0600
parents 97d80437cb80
children 0f8aeb31678c
files dmd/root.c
diffstat 1 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/dmd/root.c	Thu Mar 12 23:48:43 2009 +0100
+++ b/dmd/root.c	Thu Mar 12 17:10:24 2009 -0600
@@ -1391,7 +1391,11 @@
     //printf("OutBuffer::reserve: size = %d, offset = %d, nbytes = %d\n", size, offset, nbytes);
     if (size - offset < nbytes)
     {
-	size = (offset + nbytes) * 2;
+#if defined (__x86_64__)
+	size = (offset + nbytes) * 2 + 2;
+#else
+	size = (offset + nbytes) * 2 + 2;
+#endif
 	data = (unsigned char *)mem.realloc(data, size);
     }
 }