aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/avio.c
diff options
context:
space:
mode:
authorMans Rullgard <mans@mansr.com>2012-06-21 20:31:44 +0100
committerMans Rullgard <mans@mansr.com>2012-06-22 17:15:36 +0100
commit896bb0d742a513b1bb5b9a770dbffd2cd436bed6 (patch)
treebc133c53f4cd418c8b42c6d12958e719900ebb6e /libavformat/avio.c
parentd3d3a32c9d389cc0d6a91b389988a225ae01c948 (diff)
downloadffmpeg-896bb0d742a513b1bb5b9a770dbffd2cd436bed6.tar.gz
Replace usleep() calls with av_usleep()
This reduces the dependency on unistd.h which is not available on all systems. Signed-off-by: Mans Rullgard <mans@mansr.com>
Diffstat (limited to 'libavformat/avio.c')
-rw-r--r--libavformat/avio.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/libavformat/avio.c b/libavformat/avio.c
index 371500e8a6..5acaf30e90 100644
--- a/libavformat/avio.c
+++ b/libavformat/avio.c
@@ -19,11 +19,10 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#include <unistd.h>
-
#include "libavutil/avstring.h"
#include "libavutil/dict.h"
#include "libavutil/opt.h"
+#include "libavutil/time.h"
#include "os_support.h"
#include "avformat.h"
#if CONFIG_NETWORK
@@ -237,7 +236,7 @@ static inline int retry_transfer_wrapper(URLContext *h, unsigned char *buf, int
if (fast_retries)
fast_retries--;
else
- usleep(1000);
+ av_usleep(1000);
} else if (ret < 1)
return ret < 0 ? ret : len;
if (ret)