bool test_integrity_check(void) {
  size_t size;
  for (size = 1; size <= 16; size++) {
    {
      umm_init();
      corruption_cnt = 0;
      char *ptr = wrap_malloc(size);
      memset(ptr, 0xfe, size + 8 /* size of umm_block*/);

      /*
       * NOTE: we don't use wrap_free here, because we've just corrupted the
       * heap, and gathering of the umm info on corrupted heap can cause
       * segfault
       */
      umm_free(ptr);

      if (corruption_cnt == 0) {
        printf("corruption_cnt should not be 0, but it is\n");
        return false;
      }
    }

    {
      umm_init();
      corruption_cnt = 0;
      char *ptr = wrap_calloc(1, size);
      ptr[-1]++;

      /*
       * NOTE: we don't use wrap_free here, because we've just corrupted the
       * heap, and gathering of the umm info on corrupted heap can cause
       * segfault
       */
      umm_free(ptr);

      if (corruption_cnt == 0) {
        printf("corruption_cnt should not be 0, but it is\n");
        return false;
      }
    }
  }

  return true;
}
bool test_integrity_check(void) {
  size_t size;
  for (size = 1; size <= 16; size++) {
    {
      umm_init();
      corruption_cnt = 0;
      char *ptr = wrap_malloc(size);
      memset(ptr, 0xfe, size + 8  );

       
      umm_free(ptr);

      if (corruption_cnt == 0) {
        printf("corruption_cnt should not be 0, but it is\n");
        return false;
      }
    }

    {
      umm_init();
      corruption_cnt = 0;
      char *ptr = wrap_calloc(1, size);
      ptr[-1]++;

       
      umm_free(ptr);

      if (corruption_cnt == 0) {
        printf("corruption_cnt should not be 0, but it is\n");
        return false;
      }
    }
  }

  return true;
}