We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fabef30 commit c8a6b52Copy full SHA for c8a6b52
src/backend/utils/mmgr/mcxt.c
@@ -14,7 +14,7 @@
14
*
15
16
* IDENTIFICATION
17
- * $PostgreSQL: pgsql/src/backend/utils/mmgr/mcxt.c,v 1.54 2005/02/18 21:52:33 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/utils/mmgr/mcxt.c,v 1.55 2005/05/14 23:16:29 tgl Exp $
18
19
*-------------------------------------------------------------------------
20
*/
@@ -123,7 +123,10 @@ MemoryContextReset(MemoryContext context)
123
{
124
AssertArg(MemoryContextIsValid(context));
125
126
- MemoryContextResetChildren(context);
+ /* save a function call in common case where there are no children */
127
+ if (context->firstchild != NULL)
128
+ MemoryContextResetChildren(context);
129
+
130
(*context->methods->reset) (context);
131
}
132
0 commit comments