summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorChristopher Michael <devilhorns@comcast.net>2021-02-17 10:52:20 -0500
committerChristopher Michael <devilhorns@comcast.net>2021-02-17 10:53:15 -0500
commit1842d3997a88e22421eddeed49be50a0db08b7ce (patch)
tree17b4f5b55691498cf0f1f24a791db674662154f3 /src/lib
parentccf77acc2202ee3f4e649c7bb24116302b512508 (diff)
Revert "ecore: Update to not use deprecated mallinfo"
Reverting this, for now, because some distro's are still not updated... This should probably use a malloc version check, but I don't have time this week for a proper fix... This reverts commit 17137316eeb728a30c3c14e4b3a2f1cd8765bbfc.
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/ecore/ecore.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/lib/ecore/ecore.c b/src/lib/ecore/ecore.c
index c3ffaa4165..0d79b621b2 100644
--- a/src/lib/ecore/ecore.c
+++ b/src/lib/ecore/ecore.c
@@ -51,8 +51,8 @@ EAPI double _efl_startup_time = 0;
51 Global = Local; 51 Global = Local;
52 52
53static Eina_Bool _ecore_memory_statistic(void *data); 53static Eina_Bool _ecore_memory_statistic(void *data);
54static size_t _ecore_memory_max_total = 0; 54static int _ecore_memory_max_total = 0;
55static size_t _ecore_memory_max_free = 0; 55static int _ecore_memory_max_free = 0;
56static pid_t _ecore_memory_pid = 0; 56static pid_t _ecore_memory_pid = 0;
57#ifdef HAVE_MALLOC_INFO 57#ifdef HAVE_MALLOC_INFO
58static FILE *_ecore_memory_statistic_file = NULL; 58static FILE *_ecore_memory_statistic_file = NULL;
@@ -437,7 +437,7 @@ ecore_shutdown(void)
437 { 437 {
438 _ecore_memory_statistic(NULL); 438 _ecore_memory_statistic(NULL);
439 439
440 ERR("[%i] Memory MAX total: %lu, free: %lu", 440 ERR("[%i] Memory MAX total: %i, free: %i",
441 _ecore_memory_pid, 441 _ecore_memory_pid,
442 _ecore_memory_max_total, 442 _ecore_memory_max_total,
443 _ecore_memory_max_free); 443 _ecore_memory_max_free);
@@ -971,12 +971,12 @@ _ecore_memory_statistic(EINA_UNUSED void *data)
971 static int frame = 0; 971 static int frame = 0;
972#endif 972#endif
973#ifdef HAVE_MALLINFO 973#ifdef HAVE_MALLINFO
974 struct mallinfo2 mi; 974 struct mallinfo mi;
975 static size_t uordblks = 0; 975 static int uordblks = 0;
976 static size_t fordblks = 0; 976 static int fordblks = 0;
977 Eina_Bool changed = EINA_FALSE; 977 Eina_Bool changed = EINA_FALSE;
978 978
979 mi = mallinfo2(); 979 mi = mallinfo();
980 980
981#define HAS_CHANGED(Global, Local) \ 981#define HAS_CHANGED(Global, Local) \
982 if (Global != Local) \ 982 if (Global != Local) \
@@ -989,7 +989,7 @@ _ecore_memory_statistic(EINA_UNUSED void *data)
989 HAS_CHANGED(fordblks, mi.fordblks); 989 HAS_CHANGED(fordblks, mi.fordblks);
990 990
991 if (changed) 991 if (changed)
992 ERR("[%i] Memory total: %lu, free: %lu", 992 ERR("[%i] Memory total: %i, free: %i",
993 _ecore_memory_pid, 993 _ecore_memory_pid,
994 mi.uordblks, 994 mi.uordblks,
995 mi.fordblks); 995 mi.fordblks);