partition_check_memory.c 563 B

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