mirror of
https://github.com/EnterpriseDB/repmgr.git
synced 2026-03-26 00:26:30 +00:00
Use pg_malloc0() instead of malloc()
This commit is contained in:
2
config.c
2
config.c
@@ -579,7 +579,7 @@ tablespace_list_append(t_configuration_options *options, const char *arg)
|
|||||||
char *dst_ptr;
|
char *dst_ptr;
|
||||||
const char *arg_ptr;
|
const char *arg_ptr;
|
||||||
|
|
||||||
cell = (TablespaceListCell *) malloc(sizeof(TablespaceListCell));
|
cell = (TablespaceListCell *) pg_malloc0(sizeof(TablespaceListCell));
|
||||||
if(cell == NULL)
|
if(cell == NULL)
|
||||||
{
|
{
|
||||||
log_err(_("unable to allocate memory. Terminating.\n"));
|
log_err(_("unable to allocate memory. Terminating.\n"));
|
||||||
|
|||||||
Reference in New Issue
Block a user