aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/backend/postmaster/postmaster.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c
index 6bb2a474857..b7f99fc18d3 100644
--- a/src/backend/postmaster/postmaster.c
+++ b/src/backend/postmaster/postmaster.c
@@ -1462,10 +1462,12 @@ DetermineSleepTime(struct timeval * timeout)
if (next_wakeup != 0)
{
+ long secs;
int microsecs;
TimestampDifference(GetCurrentTimestamp(), next_wakeup,
- &timeout->tv_sec, &microsecs);
+ &secs, &microsecs);
+ timeout->tv_sec = secs;
timeout->tv_usec = microsecs;
/* Ensure we don't exceed one minute */