diff options
author | Christian Hesse <mail@eworm.de> | 2016-10-11 10:42:53 +0200 |
---|---|---|
committer | Christian Hesse <mail@eworm.de> | 2016-10-11 10:42:53 +0200 |
commit | 19ea85ef12ada79d19f4661c5966f57730c80dfc (patch) | |
tree | 7844fe645bc68c2b12070d40bce6f2420d8f4da3 /pacredir.c | |
parent | 37bc50d90551a2580f7762d8527e76663fddab20 (diff) | |
download | pacredir-19ea85ef12ada79d19f4661c5966f57730c80dfc.tar.gz pacredir-19ea85ef12ada79d19f4661c5966f57730c80dfc.tar.zst |
throttle requests
Diffstat (limited to 'pacredir.c')
-rw-r--r-- | pacredir.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -386,6 +386,10 @@ static int ahc_echo(void * cls, break; } + /* throttle requests - do not send all request at the same time + * but wait for a short moment (10.000 us = 0.01 s) */ + usleep(10000); + /* This is multi-threading code! * Pointer to struct request does not work as realloc can relocate the data. * We need a pointer to pointer to struct request, store the addresses in |