aboutsummaryrefslogtreecommitdiffstats
path: root/cmdutils.h
diff options
context:
space:
mode:
authorStefano Sabatini <stefano.sabatini-lala@poste.it>2010-04-01 22:34:22 +0000
committerStefano Sabatini <stefano.sabatini-lala@poste.it>2010-04-01 22:34:22 +0000
commit458b062d61a92d725cde9363941747a1c6d1e575 (patch)
treeee10867788ffec5cb35c5bcc4a52b29e182a3005 /cmdutils.h
parent339f5f39573dcdcb16f2dba563f784340a61b189 (diff)
downloadffmpeg-458b062d61a92d725cde9363941747a1c6d1e575.tar.gz
Implement cmdutils.c:read_file(), and use it in ffmpeg.c for reading
the second pass encoding log file. Originally committed as revision 22769 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'cmdutils.h')
-rw-r--r--cmdutils.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/cmdutils.h b/cmdutils.h
index 549ade8767..ad8cefdeee 100644
--- a/cmdutils.h
+++ b/cmdutils.h
@@ -200,4 +200,15 @@ void show_pix_fmts(void);
*/
int read_yesno(void);
+/**
+ * Reads the file with name filename, and puts its content in a newly
+ * allocated 0-terminated buffer.
+ *
+ * @param bufptr puts here the pointer to the newly allocated buffer
+ * @param size puts here the size of the newly allocated buffer
+ * @return 0 in case of success, a negative value corresponding to an
+ * AVERROR error code in case of failure.
+ */
+int read_file(const char *filename, char **bufptr, size_t *size);
+
#endif /* FFMPEG_CMDUTILS_H */