Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit1038542

Browse files
committed
fix bug in MtmNoticeReceiver
1 parent6ae8d72 commit1038542

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎contrib/mmts/multimaster.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4582,7 +4582,7 @@ MtmNoticeReceiver(void *i, const PGresult *res)
45824582
if ( (*(int*)i)!=MtmNodeId-1)
45834583
return;
45844584

4585-
stripped_notice=palloc0(len);
4585+
stripped_notice=palloc0(len+1);
45864586

45874587
if (*notice=='N')
45884588
{
@@ -4598,7 +4598,7 @@ MtmNoticeReceiver(void *i, const PGresult *res)
45984598
}
45994599
else
46004600
{
4601-
stripped_notice=notice;
4601+
strncpy(stripped_notice,notice,len+1);
46024602
MTM_ELOG(WARNING,"%s",stripped_notice);
46034603
}
46044604

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp