partition_check_memory.c 622 B

123456789101112131415161718192021222324
  1. /*
  2. * partition_check_memory.c
  3. */
  4. #include "private.h"
  5. /*-------------------------------------------------------- */
  6. bool_t
  7. lub_partition_check_memory(lub_partition_t *this)
  8. {
  9. bool_t result = BOOL_TRUE;
  10. lub_heap_t *local_heap = lub_partition__get_local_heap(this);
  11. if(local_heap)
  12. {
  13. result = lub_heap_check_memory(local_heap);
  14. }
  15. if(BOOL_TRUE == result)
  16. {
  17. lub_partition_lock(this);
  18. result = lub_heap_check_memory(this->m_global_heap);
  19. lub_partition_unlock(this);
  20. }
  21. return result;
  22. }
  23. /*-------------------------------------------------------- */