last performance improvements, and typemaps fixes

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7865 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Marcelo Matus 2005-11-24 09:20:24 +00:00
commit f3acf52370
5 changed files with 164 additions and 46 deletions

View file

@ -434,9 +434,9 @@ DohString_putc(DOH *so, int ch)
register char *tc;
maxsize = s->maxsize;
if (len > (maxsize-2)) {
s->str = (char *) DohRealloc(s->str,3*maxsize);
s->str = (char *) DohRealloc(s->str,2*maxsize);
assert(s->str);
s->maxsize = 3*maxsize;
s->maxsize = 2*maxsize;
}
tc = s->str + len;
*(tc++) = ch;