summaryrefslogtreecommitdiff
path: root/libavformat
diff options
context:
space:
mode:
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/ffm.h4
-rw-r--r--libavformat/ffmdec.c33
-rw-r--r--libavformat/network.h1
3 files changed, 1 insertions, 37 deletions
diff --git a/libavformat/ffm.h b/libavformat/ffm.h
index 49402355f4..b392b8d8d8 100644
--- a/libavformat/ffm.h
+++ b/libavformat/ffm.h
@@ -57,8 +57,4 @@ typedef struct FFMContext {
int64_t start_time;
} FFMContext;
-int64_t ffm_read_write_index(int fd);
-int ffm_write_write_index(int fd, int64_t pos);
-void ffm_set_write_index(AVFormatContext *s, int64_t pos, int64_t file_size);
-
#endif /* AVFORMAT_FFM_H */
diff --git a/libavformat/ffmdec.c b/libavformat/ffmdec.c
index f151f9c1f4..7cbcf2bf2a 100644
--- a/libavformat/ffmdec.c
+++ b/libavformat/ffmdec.c
@@ -25,39 +25,6 @@
#include "internal.h"
#include "ffm.h"
#include "avio_internal.h"
-#if CONFIG_FFSERVER
-#include <unistd.h>
-
-int64_t ffm_read_write_index(int fd)
-{
- uint8_t buf[8];
-
- lseek(fd, 8, SEEK_SET);
- if (read(fd, buf, 8) != 8)
- return AVERROR(EIO);
- return AV_RB64(buf);
-}
-
-int ffm_write_write_index(int fd, int64_t pos)
-{
- uint8_t buf[8];
- int i;
-
- for(i=0;i<8;i++)
- buf[i] = (pos >> (56 - i * 8)) & 0xff;
- lseek(fd, 8, SEEK_SET);
- if (write(fd, buf, 8) != 8)
- return AVERROR(EIO);
- return 8;
-}
-
-void ffm_set_write_index(AVFormatContext *s, int64_t pos, int64_t file_size)
-{
- FFMContext *ffm = s->priv_data;
- ffm->write_index = pos;
- ffm->file_size = file_size;
-}
-#endif // CONFIG_FFSERVER
static int ffm_is_avail_data(AVFormatContext *s, int size)
{
diff --git a/libavformat/network.h b/libavformat/network.h
index 51d855daf9..a766d03fcd 100644
--- a/libavformat/network.h
+++ b/libavformat/network.h
@@ -22,6 +22,7 @@
#define AVFORMAT_NETWORK_H
#include <errno.h>
+#include <stdint.h>
#include "config.h"
#include "libavutil/error.h"