mirror of
https://github.com/postgres/postgres.git
synced 2025-06-14 18:42:34 +03:00
Use NULL instead of 0 for pointer arguments.
Commit 5fe08c006c
fixed this for calls to dshash_create(). This
commit fixes calls to dshash_attach() and dsa_create_in_place().
Reviewed-by: Masahiko Sawada <sawada.mshk@gmail.com>
Reviewed-by: Michael Paquier <michael@paquier.xyz>
Discussion: https://postgr.es/m/aECi_gSD9JnVWQ8T%40nathan
This commit is contained in:
@ -1016,7 +1016,7 @@ logicalrep_launcher_attach_dshmem(void)
|
|||||||
last_start_times_dsa = dsa_attach(LogicalRepCtx->last_start_dsa);
|
last_start_times_dsa = dsa_attach(LogicalRepCtx->last_start_dsa);
|
||||||
dsa_pin_mapping(last_start_times_dsa);
|
dsa_pin_mapping(last_start_times_dsa);
|
||||||
last_start_times = dshash_attach(last_start_times_dsa, &dsh_params,
|
last_start_times = dshash_attach(last_start_times_dsa, &dsh_params,
|
||||||
LogicalRepCtx->last_start_dsh, 0);
|
LogicalRepCtx->last_start_dsh, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
MemoryContextSwitchTo(oldcontext);
|
MemoryContextSwitchTo(oldcontext);
|
||||||
|
@ -183,7 +183,7 @@ StatsShmemInit(void)
|
|||||||
p += MAXALIGN(pgstat_dsa_init_size());
|
p += MAXALIGN(pgstat_dsa_init_size());
|
||||||
dsa = dsa_create_in_place(ctl->raw_dsa_area,
|
dsa = dsa_create_in_place(ctl->raw_dsa_area,
|
||||||
pgstat_dsa_init_size(),
|
pgstat_dsa_init_size(),
|
||||||
LWTRANCHE_PGSTATS_DSA, 0);
|
LWTRANCHE_PGSTATS_DSA, NULL);
|
||||||
dsa_pin(dsa);
|
dsa_pin(dsa);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -255,7 +255,8 @@ pgstat_attach_shmem(void)
|
|||||||
dsa_pin_mapping(pgStatLocal.dsa);
|
dsa_pin_mapping(pgStatLocal.dsa);
|
||||||
|
|
||||||
pgStatLocal.shared_hash = dshash_attach(pgStatLocal.dsa, &dsh_params,
|
pgStatLocal.shared_hash = dshash_attach(pgStatLocal.dsa, &dsh_params,
|
||||||
pgStatLocal.shmem->hash_handle, 0);
|
pgStatLocal.shmem->hash_handle,
|
||||||
|
NULL);
|
||||||
|
|
||||||
MemoryContextSwitchTo(oldcontext);
|
MemoryContextSwitchTo(oldcontext);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user