[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lua alloc function with just malloc and free causes crash
- From: Klaus Ripke <paul-lua@...>
- Date: Sat, 5 Aug 2006 16:48:12 +0200
On Sat, Aug 05, 2006 at 10:16:47AM -0400, John D. Ramsdell wrote:
> else if (osize > nsize) {
> void *p = malloc(nsize);
> if (p == NULL)
> return ptr;
> memcpy(p, ptr, osize);
how about using nsize here?