diff options
author | Mans Rullgard <mans@mansr.com> | 2012-06-21 20:31:44 +0100 |
---|---|---|
committer | Mans Rullgard <mans@mansr.com> | 2012-06-22 17:15:36 +0100 |
commit | 896bb0d742a513b1bb5b9a770dbffd2cd436bed6 (patch) | |
tree | bc133c53f4cd418c8b42c6d12958e719900ebb6e /libavformat/rtmphttp.c | |
parent | d3d3a32c9d389cc0d6a91b389988a225ae01c948 (diff) | |
download | ffmpeg-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/rtmphttp.c')
-rw-r--r-- | libavformat/rtmphttp.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/libavformat/rtmphttp.c b/libavformat/rtmphttp.c index 544b493500..499341a173 100644 --- a/libavformat/rtmphttp.c +++ b/libavformat/rtmphttp.c @@ -24,11 +24,10 @@ * RTMP HTTP protocol */ -#include <unistd.h> - #include "libavutil/avstring.h" #include "libavutil/intfloat.h" #include "libavutil/opt.h" +#include "libavutil/time.h" #include "internal.h" #include "http.h" @@ -126,7 +125,7 @@ static int rtmp_http_read(URLContext *h, uint8_t *buf, int size) if (rt->nb_bytes_read == 0) { /* Wait 50ms before retrying to read a server reply in * order to reduce the number of idle requets. */ - usleep(50000); + av_usleep(50000); } if ((ret = rtmp_http_write(h, "", 1)) < 0) |