mirror of
https://git.postgresql.org/git/postgresql.git
synced 2024-12-27 08:39:28 +08:00
Fix compiler warning in WaitForBackgroundWorkerStartup().
Per complaint from Andrew Gierth.
This commit is contained in:
parent
6e5f6e5913
commit
496439d943
@ -863,7 +863,6 @@ BgwHandleStatus
|
||||
WaitForBackgroundWorkerStartup(BackgroundWorkerHandle *handle, pid_t *pidp)
|
||||
{
|
||||
BgwHandleStatus status;
|
||||
pid_t pid;
|
||||
int rc;
|
||||
bool save_set_latch_on_sigusr1;
|
||||
|
||||
@ -874,9 +873,13 @@ WaitForBackgroundWorkerStartup(BackgroundWorkerHandle *handle, pid_t *pidp)
|
||||
{
|
||||
for (;;)
|
||||
{
|
||||
pid_t pid;
|
||||
|
||||
CHECK_FOR_INTERRUPTS();
|
||||
|
||||
status = GetBackgroundWorkerPid(handle, &pid);
|
||||
if (status == BGWH_STARTED)
|
||||
*pidp = pid;
|
||||
if (status != BGWH_NOT_YET_STARTED)
|
||||
break;
|
||||
|
||||
@ -900,6 +903,5 @@ WaitForBackgroundWorkerStartup(BackgroundWorkerHandle *handle, pid_t *pidp)
|
||||
PG_END_TRY();
|
||||
|
||||
set_latch_on_sigusr1 = save_set_latch_on_sigusr1;
|
||||
*pidp = pid;
|
||||
return status;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user