_expand() and _msize()
In windows I could use _expand() to take a piece of memory and enlarge it and _msize() to determine what the memory size in bytes (which I got from malloc.h, I think) is but in Linux I got compiling errors with those 2 functions.
I just want to know if there are Linux equivalent functions for C++ ? |
In general you should be using new and delete in C++ to allocate memory.
However... if your interested... the following C functions exist under Linux. malloc - allocates memory realloc - reallocates a memory block (allows you to change the size). malloc_size - reports the size of a block you have allocated EDIT: btw... they are all availible in stdlib.h. |
All times are GMT -5. The time now is 04:04 PM. |