Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit dceff14

Browse files
Andrei KrichininMikhail Rutman
Andrei Krichinin
authored and
Mikhail Rutman
committed
Multimaster init_cluster() with empty nodes list: replace assertion with error report.
Tags: multimaster.
1 parent ef0c766 commit dceff14

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/multimaster.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -933,7 +933,8 @@ mtm_init_cluster(PG_FUNCTION_ARGS)
933933

934934
/* parse array with peer connstrings */
935935
Assert(ARR_ELEMTYPE(peers_arr) == TEXTOID);
936-
Assert(ARR_NDIM(peers_arr) == 1);
936+
if (ARR_NDIM(peers_arr) != 1)
937+
mtm_log(ERROR, "node list should not be empty");
937938
deconstruct_array(peers_arr,
938939
TEXTOID, -1, false, 'i',
939940
&peers_datums, &peers_nulls, &n_peers);

0 commit comments

Comments
 (0)