libcm is a C development framework with an emphasis on audio signal processing applications.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

cmMain.c 722B

123456789101112131415161718192021222324252627282930313233
  1. #include "cmGlobal.h"
  2. #include "cmRpt.h"
  3. #include "cmMem.h"
  4. #include "cmMallocDebug.h"
  5. #include "cmLinkedHeap.h"
  6. void print(void* cmRptUserPtr, const char* text)
  7. { printf(text); }
  8. int main(int argc, char* argv[] )
  9. {
  10. // initialize the heap check library
  11. bool memDebugFl = true;
  12. unsigned memPadByteCnt = memDebugFl ? 8 : 0;
  13. unsigned memAlignByteCnt = 16;
  14. unsigned memFlags = memDebugFl ? kTrackMmFl | kDeferFreeMmFl | kFillUninitMmFl : 0;
  15. cmRpt_t rpt;
  16. cmRptSetup(&rpt,print,print,NULL);
  17. //cmMdTest(&rpt);
  18. //return 0;
  19. cmMdInitialize( memPadByteCnt, memAlignByteCnt, memFlags, &rpt );
  20. cmLHeapTest();
  21. cmMdReport();
  22. cmMdFinalize();
  23. return 0;
  24. }