summaryrefslogtreecommitdiffstats
path: root/libavformat/avio_internal.h
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-06-01 00:43:47 +0200
committerMichael Niedermayer <michaelni@gmx.at>2015-06-01 00:43:50 +0200
commitebab902a1c3670c1e445d144f1d4365f32955a85 (patch)
tree0d7fafd2563d5b40f32c172abc4dceea773336a7 /libavformat/avio_internal.h
parent3bd43430f86d58dac31add7b3913563622430eb1 (diff)
parentbff0349d9da527084e1433167466d8afc9e25c7f (diff)
downloadffmpeg-streaming-ebab902a1c3670c1e445d144f1d4365f32955a85.zip
ffmpeg-streaming-ebab902a1c3670c1e445d144f1d4365f32955a85.tar.gz
Merge commit 'bff0349d9da527084e1433167466d8afc9e25c7f'
* commit 'bff0349d9da527084e1433167466d8afc9e25c7f': avio: Add avio_read wrapper to simplify error checking Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/avio_internal.h')
-rw-r--r--libavformat/avio_internal.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/libavformat/avio_internal.h b/libavformat/avio_internal.h
index 1ed5831..ad50567 100644
--- a/libavformat/avio_internal.h
+++ b/libavformat/avio_internal.h
@@ -85,6 +85,13 @@ int ffio_rewind_with_probe_data(AVIOContext *s, unsigned char **buf, int buf_siz
uint64_t ffio_read_varlen(AVIOContext *bc);
+/**
+ * Read size bytes from AVIOContext into buf.
+ * Check that exactly size bytes have been read.
+ * @return number of bytes read or AVERROR
+ */
+int ffio_read_size(AVIOContext *s, unsigned char *buf, int size);
+
/** @warning must be called before any I/O */
int ffio_set_buf_size(AVIOContext *s, int buf_size);
OpenPOWER on IntegriCloud