summaryrefslogtreecommitdiff
path: root/src/backend/utils/mmgr
diff options
context:
space:
mode:
authorTomas Vondra2019-10-05 18:49:39 +0000
committerTomas Vondra2019-10-05 18:49:39 +0000
commit36425ece5d6c78177cdc1453a9925a0bb85da59f (patch)
tree57fd79f7b0c3a73364fe81cb2bea698a9de16875 /src/backend/utils/mmgr
parente800bd7414df3ce8170761e5b75b13e83f576988 (diff)
Change MemoryContextMemAllocated to return Size
Commit f2369bc610 switched most of the memory accounting from int64 to Size, but it forgot to change the MemoryContextMemAllocated return type. So this fixes that omission. Discussion: https://www.postgresql.org/message-id/11238.1570200198%40sss.pgh.pa.us
Diffstat (limited to 'src/backend/utils/mmgr')
-rw-r--r--src/backend/utils/mmgr/mcxt.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/backend/utils/mmgr/mcxt.c b/src/backend/utils/mmgr/mcxt.c
index 7bbfabe0eab..d52bd2c073c 100644
--- a/src/backend/utils/mmgr/mcxt.c
+++ b/src/backend/utils/mmgr/mcxt.c
@@ -466,10 +466,10 @@ MemoryContextIsEmpty(MemoryContext context)
* Find the memory allocated to blocks for this memory context. If recurse is
* true, also include children.
*/
-int64
+Size
MemoryContextMemAllocated(MemoryContext context, bool recurse)
{
- int64 total = context->mem_allocated;
+ Size total = context->mem_allocated;
AssertArg(MemoryContextIsValid(context));