[OCLUG-devel] malloc() woes

James Colannino james at colannino.org
Sun May 29 13:32:18 PDT 2005


Dan Stromberg wrote:

>You'll probably want to declare your initial "buffer" as a char *, and
>then get some memory for it via malloc(), when you first need to use it.
>
>Then if/when you're ready to change the amount of memory pointed to by
>buffer, you'll probably want to use realloc().
>  
>

That's a good idea.  I'll give that a go and see what happens.  Thanks :)

James

-- 
My blog: http://www.crazydrclaw.com/
My homepage: http://james.colannino.org/

"A well regulated militia being necessary to the security of a free
state, THE RIGHT of the people to keep and bear arms SHALL NOT BE
INFRINGED." --United States Constitution, Second Ammendment



More information about the OCLUG-devel mailing list