Re: [Patch] - for memory.c

2001-12-09 Thread David & Lisa Jacobs
[EMAIL PROTECTED]> Sent: Sunday, December 09, 2001 5:16 PM Subject: Re: [Patch] - for memory.c > Thanks for the catch! > > How about just adding the limit check back in. > > for (i=1; (size>i) && (i<0xff); i<<=1); > > Do you like the rest of the changes

Re: [Patch] - for memory.c

2001-12-09 Thread David & Lisa Jacobs
Thanks for the catch! How about just adding the limit check back in. for (i=1; (size>i) && (i<0xff); i<<=1); Do you like the rest of the changes I made to the algorithm? David Jacobs - Original Message - From: "Sam Tregar" <[EMAIL PROTECTED]> > > +for (i = 1; size > i; i <<=

Re: [Patch] - for memory.c

2001-12-09 Thread Sam Tregar
On Sun, 9 Dec 2001, David Jacobs wrote: > +for (i = 1; size > i; i <<= 1); Infinite loop if size == MAXINT, eh? "So don't do that." Ok. -sam

[Patch] - for memory.c

2001-12-09 Thread David Jacobs
This small patch cleans up two things with the allocate aligned memory routine. It cleans up the for loop eliminating the need for the bit operations inside and making it a bit clearer what is happening. It also reduces the memory allocated from twice the rounded up power of two to the rounde