!3048 修复gs_basebackup用默认xlog传输方式 -X 参数提示密码错误

Merge pull request !3048 from 仲夏十三/mas9
This commit is contained in:
opengauss-bot 2023-03-08 07:18:57 +00:00 committed by Gitee
commit cee4f486b3
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 1 additions and 2 deletions

View File

@ -1154,8 +1154,6 @@ static void BaseBackup(void)
/* Error message already written in GetConnection() */ /* Error message already written in GetConnection() */
exit(1); exit(1);
ClearAndFreePasswd();
/* /*
* Run IDENTIFY_SYSTEM so we can get the timeline * Run IDENTIFY_SYSTEM so we can get the timeline
*/ */
@ -1335,6 +1333,7 @@ static void BaseBackup(void)
StartLogStreamer((const char *)xlogstart, timeline, sysidentifier); StartLogStreamer((const char *)xlogstart, timeline, sysidentifier);
} }
ClearAndFreePasswd();
/* free sysidentifier after use */ /* free sysidentifier after use */
PQfreemem(sysidentifier); PQfreemem(sysidentifier);
sysidentifier = NULL; sysidentifier = NULL;