Skip to content

Commit

Permalink
Change prototype to match upstream change from ffmpeg trunk to fix bu…
Browse files Browse the repository at this point in the history
…ild with system ffmpeg.

Declare the url_write buffer parameter as const
BUG=45821
TEST=Build with use_system_ffmpeg on and off (1/0).


git-svn-id: svn://svn.chromium.org/chrome/trunk/src@49139 0039d316-1c4b-4281-b951-d872f2087c98
  • Loading branch information
fbarchard@chromium.org committed Jun 8, 2010
1 parent 8be9ff2 commit 084283d
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -78,3 +78,4 @@ Benjamin Jemlich <pcgod99@gmail.com>
Ningxin Hu <ningxin.hu@intel.com>
Jared Wein <weinjared@gmail.com>
Mingmin Xie <melvinxie@gmail.com>
Michael Gilbert <floppymaster@gmail.com>
4 changes: 4 additions & 0 deletions media/ffmpeg/file_protocol.cc
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,11 @@ int ReadContext(URLContext* h, unsigned char* buf, int size) {
return HANDLE_EINTR(read(GetHandle(h), buf, size));
}

#if LIBAVFORMAT_VERSION_INT >= AV_VERSION_INT(52, 68, 0)
int WriteContext(URLContext* h, const unsigned char* buf, int size) {
#else
int WriteContext(URLContext* h, unsigned char* buf, int size) {
#endif
return HANDLE_EINTR(write(GetHandle(h), buf, size));
}

Expand Down
4 changes: 4 additions & 0 deletions media/filters/ffmpeg_glue.cc
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,11 @@ int ReadContext(URLContext* h, unsigned char* buf, int size) {
return result;
}

#if LIBAVFORMAT_VERSION_INT >= AV_VERSION_INT(52, 68, 0)
int WriteContext(URLContext* h, const unsigned char* buf, int size) {
#else
int WriteContext(URLContext* h, unsigned char* buf, int size) {
#endif
// We don't support writing.
return AVERROR_IO;
}
Expand Down

0 comments on commit 084283d

Please sign in to comment.