Enable allocation tracking for eng and userdebug builds.
This change will result in a constant increase in memory utilization
per allocation but will help us catch memory errors earlier.
diff --git a/osi/src/semaphore.c b/osi/src/semaphore.c
index e27e201..6ccd905 100644
--- a/osi/src/semaphore.c
+++ b/osi/src/semaphore.c
@@ -43,7 +43,7 @@
ret->fd = eventfd(value, EFD_SEMAPHORE);
if (ret->fd == INVALID_FD) {
ALOGE("%s unable to allocate semaphore: %s", __func__, strerror(errno));
- free(ret);
+ osi_free(ret);
ret = NULL;
}
}