error: malloc.h: No such file or directory
error: malloc.h: No such file or directory
i tryed to #include <malloc.h> in order to use malloc to create a pseudo array. does xcode even have this library? can i dl it somewhere and use it? or does malloc.h a different name in xcode?
i tryed to #include <malloc.h> in order to use malloc to create a pseudo array. does xcode even have this library? can i dl it somewhere and use it? or does malloc.h a different name in xcode?
nvm i found out that malloc was placed inside stdlib.h
oh well. forgetting to go to google first = my moment of stupid.
oh well. forgetting to go to google first = my moment of stupid.
I did this in one of my projects I'm working on and it works.
#ifdef __WXMAC__
#include "sys/malloc.h" // mac os x
#else
#include "malloc.h" // linux, windows
#endif
If you don't use wxWidgets maybe change WXMAC to just MAC?
( I program for mac/linux/windows so I care not only about just for mac. )
#ifdef __WXMAC__
#include "sys/malloc.h" // mac os x
#else
#include "malloc.h" // linux, windows
#endif
If you don't use wxWidgets maybe change WXMAC to just MAC?
( I program for mac/linux/windows so I care not only about just for mac. )
Possibly Related Threads...
| Thread: | Author | Replies: | Views: | Last Post | |
| Malloc() Struct with NSString Inside? | Graphic Ace | 3 | 3,791 |
Jan 26, 2010 05:32 PM Last Post: cmiller |
|

