#include <storage.h>
#include <system_info.h>
#include <runtime_info.h>
+#include <malloc.h>
#define MUSE_STORAGE_EXTERNAL_FEATURE "http://tizen.org/feature/storage.external"
{
int used_pss = 0;
process_memory_info_s *info = NULL;
- int ret = runtime_info_get_process_memory_info(&pid, 1, &info);
+ int ret = 0;
- if (MM_ERROR_NONE == ret && info)
+ if (malloc_trim(0) == 0)
+ LOGW("It was not possible to release any memory");
+
+ ret = runtime_info_get_process_memory_info(&pid, 1, &info);
+
+ if (RUNTIME_INFO_ERROR_NONE == ret && info)
used_pss = info->pss;
else
LOGE("Fail to get process (%d) memory %s", pid, get_error_message(ret));