Re: TODO-item: Add sleep() function, remove from regress.c - Mailing list pgsql-patches

From Tom Lane
Subject Re: TODO-item: Add sleep() function, remove from regress.c
Date
Msg-id 23934.1136858089@sss.pgh.pa.us
Whole thread Raw
In response to TODO-item: Add sleep() function, remove from regress.c  (Joachim Wieland <joe@mcknight.de>)
Responses Re: TODO-item: Add sleep() function, remove from regress.c  (Joachim Wieland <joe@mcknight.de>)
List pgsql-patches
BTW, a serious problem with just passing it off to pg_usleep like that
is that the sleep can't be aborted by a cancel request; doesn't seem
like a good idea to me.  I'd suggest writing a loop that sleeps for at
most a second at a time, with a CHECK_FOR_INTERRUPTS() before each
sleep.  This would also allow you to eliminate the arbitrary restriction
on length of sleep.

            regards, tom lane

pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: TODO-item: Add sleep() function, remove from regress.c
Next
From: Bruce Momjian
Date:
Subject: Re: [HACKERS] Inconsistent syntax in GRANT