Skip to content

Commit 1998261

Browse files
committed
Avoid using a C++ keyword as a structure member name.
Per request from Peter Eisentraut.
1 parent 929ca96 commit 1998261

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

src/backend/access/transam/parallel.c

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -266,8 +266,9 @@ InitializeParallelDSM(ParallelContext *pcxt)
266266
else
267267
{
268268
pcxt->nworkers = 0;
269-
pcxt->private = MemoryContextAlloc(TopMemoryContext, segsize);
270-
pcxt->toc = shm_toc_create(PARALLEL_MAGIC, pcxt->private, segsize);
269+
pcxt->private_memory = MemoryContextAlloc(TopMemoryContext, segsize);
270+
pcxt->toc = shm_toc_create(PARALLEL_MAGIC, pcxt->private_memory,
271+
segsize);
271272
}
272273

273274
/* Initialize fixed-size state in shared memory. */
@@ -538,10 +539,10 @@ DestroyParallelContext(ParallelContext *pcxt)
538539
* If this parallel context is actually in backend-private memory rather
539540
* than shared memory, free that memory instead.
540541
*/
541-
if (pcxt->private != NULL)
542+
if (pcxt->private_memory != NULL)
542543
{
543-
pfree(pcxt->private);
544-
pcxt->private = NULL;
544+
pfree(pcxt->private_memory);
545+
pcxt->private_memory = NULL;
545546
}
546547

547548
/* Wait until the workers actually die. */

src/include/access/parallel.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ typedef struct ParallelContext
4141
ErrorContextCallback *error_context_stack;
4242
shm_toc_estimator estimator;
4343
dsm_segment *seg;
44-
void *private;
44+
void *private_memory;
4545
shm_toc *toc;
4646
ParallelWorkerInfo *worker;
4747
} ParallelContext;

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy