X-Git-Url: https://tinc-vpn.org/git/browse?p=tinc;a=blobdiff_plain;f=lib%2Fdropin.c;h=eb17acaad082ecb40d489bd5f7c0022cdadcd7d7;hp=89039da34c024b6427d110cfea15ccee3c08acf9;hb=e16ead8dd9d4600664058069f0695832dfe068b2;hpb=5dde6461a321ee47b06e33f8203f2acf00a31a51 diff --git a/lib/dropin.c b/lib/dropin.c index 89039da3..eb17acaa 100644 --- a/lib/dropin.c +++ b/lib/dropin.c @@ -1,7 +1,7 @@ /* dropin.c -- a set of drop-in replacements for libc functions Copyright (C) 2000-2005 Ivo Timmermans, - 2000-2009 Guus Sliepen + 2000-2011 Guus Sliepen This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -163,3 +163,11 @@ int gettimeofday(struct timeval *tv, void *tz) { return 0; } #endif + +#ifndef HAVE_USLEEP +int usleep(long long usec) { + struct timeval tv = {usec / 1000000, (usec / 1000) % 1000}; + select(0, NULL, NULL, NULL, &tv); + return 0; +} +#endif