mirror of
https://github.com/libevent/libevent.git
synced 2025-01-09 00:56:20 +08:00
make it so that test_persistent_timeout can call loopexit only once; reported by Alexander Drozdov
svn:r1062
This commit is contained in:
parent
1c927b7d2f
commit
3065389973
@ -476,7 +476,9 @@ periodic_timeout_cb(int fd, short event, void *arg)
|
||||
int *count = arg;
|
||||
|
||||
(*count)++;
|
||||
if (*count > 5) {
|
||||
if (*count == 6) {
|
||||
/* call loopexit only once - on slow machines(?), it is
|
||||
* apparently possible for this to get called twice. */
|
||||
test_ok = 1;
|
||||
event_base_loopexit(global_base, NULL);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user