Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2013-08-29 02:12:40 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-08-29 02:12:40 +0400
commit1ac57ccbc8b162ffcbede477683d3d53afa209cd (patch)
treeefb6f09b033ea26dd649c1e12564f2e898541ef4 /intern/guardedalloc
parent2f46a2cbf7a80c85734bd2b7d7cd0b5dc178f43b (diff)
correct own recent commit, malloc_usable_size() isn't valid for mmap()'d memory.
Diffstat (limited to 'intern/guardedalloc')
-rw-r--r--intern/guardedalloc/intern/mallocn.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/intern/guardedalloc/intern/mallocn.c b/intern/guardedalloc/intern/mallocn.c
index 4cc821ccce0..19e6e880b6a 100644
--- a/intern/guardedalloc/intern/mallocn.c
+++ b/intern/guardedalloc/intern/mallocn.c
@@ -649,8 +649,10 @@ void MEM_printmemlist_stats(void)
pb++;
#ifdef HAVE_MALLOC_H
- mem_in_use_slop += (sizeof(MemHead) + sizeof(MemTail) +
- malloc_usable_size((void *)membl)) - membl->len;
+ if (!membl->mmap) {
+ mem_in_use_slop += (sizeof(MemHead) + sizeof(MemTail) +
+ malloc_usable_size((void *)membl)) - membl->len;
+ }
#endif
if (membl->next)