Re: [FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header()

2014-12-19 Thread Thomas Volkert
On 12/19/2014 11:03 PM, James Almer wrote: On 19/12/14 7:00 PM, Michael Niedermayer wrote: On Fri, Dec 19, 2014 at 09:58:48PM +0100, Thomas Volkert wrote: On 12/19/2014 09:57 PM, Thomas Volkert wrote: + av_log(s, AV_LOG_ERROR, "invalid start code %c%c%c%c in RIFF header\n", tag & 0xFF, (

Re: [FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header()

2014-12-19 Thread James Almer
On 19/12/14 7:00 PM, Michael Niedermayer wrote: > On Fri, Dec 19, 2014 at 09:58:48PM +0100, Thomas Volkert wrote: >> On 12/19/2014 09:57 PM, Thomas Volkert wrote: >>> + av_log(s, AV_LOG_ERROR, "invalid start code %c%c%c%c in RIFF >>> header\n", tag & 0xFF, (tag >> 8) & 0xFF, (tag >> 16)

Re: [FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header()

2014-12-19 Thread Michael Niedermayer
On Fri, Dec 19, 2014 at 09:58:48PM +0100, Thomas Volkert wrote: > On 12/19/2014 09:57 PM, Thomas Volkert wrote: > >+av_log(s, AV_LOG_ERROR, "invalid start code %c%c%c%c in RIFF > >header\n", tag & 0xFF, (tag >> 8) & 0xFF, (tag >> 16) & 0xFF, (tag >> 24) & > >0xFF); > > return

Re: [FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header()

2014-12-19 Thread Thomas Volkert
On 12/19/2014 09:57 PM, Thomas Volkert wrote: + av_log(s, AV_LOG_ERROR, "invalid start code %c%c%c%c in RIFF header\n", tag & 0xFF, (tag >> 8) & 0xFF, (tag >> 16) & 0xFF, (tag >> 24) & 0xFF); return AVERROR_INVALIDDATA; Some remainung tabs - please, remove when commit. Best r

[FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header()

2014-12-19 Thread Thomas Volkert
From: Thomas Volkert Make it more readable and display an error message in case an invalid header is detected (the current version just returns AVERROR_INVALIDDATA) --- libavformat/wavdec.c | 31 ++- 1 file changed, 22 insertions(+), 9 deletions(-) diff --git a/libav

Re: [FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header()

2014-12-19 Thread Michael Niedermayer
On Fri, Dec 19, 2014 at 08:15:26PM +, Derek Buitenhuis wrote: > On 12/19/2014 9:09 PM, Thomas Volkert wrote: > > + av_log(s, AV_LOG_ERROR, "invalid start code %c%c%c%c in RIFF > > header\n", tag & 0xFF, (tag >> 8) & 0xFF, (tag >> 16) & 0xFF, (tag >> 24) & > > 0xFF); > > I'm sure pr

Re: [FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header()

2014-12-19 Thread Derek Buitenhuis
On 12/19/2014 9:09 PM, Thomas Volkert wrote: > + av_log(s, AV_LOG_ERROR, "invalid start code %c%c%c%c in RIFF header\n", > tag & 0xFF, (tag >> 8) & 0xFF, (tag >> 16) & 0xFF, (tag >> 24) & 0xFF); I'm sure printing possibly non-printable chars is a great idea. Nothing could go wrong. Use 0x%X

[FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header()

2014-12-19 Thread Thomas Volkert
From: Thomas Volkert Make it more readable and display an error message in case an invalid header is detected (the current version just returns AVERROR_INVALIDDATA) --- libavformat/wavdec.c | 31 ++- 1 file changed, 22 insertions(+), 9 deletions(-) diff --git a/libav

Re: [FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header() to make it more readable and display an error message in case an invalid header is detected (the current version just returns AVERROR_INVA

2014-12-18 Thread Thomas Volkert
On 18.12.2014 14:17, wm4 wrote: The commit message subject line should be at most 72 (or was it 60?) characters long. The rest should go into the body of the commit message (in raw git, the first line of the commit message is the subject, then comes an empty line, and the rest is the body of the

Re: [FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header() to make it more readable and display an error message in case an invalid header is detected (the current version just returns AVERROR_INVA

2014-12-18 Thread wm4
On Thu, 18 Dec 2014 12:50:25 +0100 Thomas Volkert wrote: > From: Thomas Volkert > The commit message subject line should be at most 72 (or was it 60?) characters long. The rest should go into the body of the commit message (in raw git, the first line of the commit message is the subject, then

[FFmpeg-devel] [PATCH] wavdec: refactor wav_read_header() to make it more readable and display an error message in case an invalid header is detected (the current version just returns AVERROR_INVALIDD

2014-12-18 Thread Thomas Volkert
From: Thomas Volkert --- libavformat/wavdec.c | 32 ++-- 1 file changed, 22 insertions(+), 10 deletions(-) diff --git a/libavformat/wavdec.c b/libavformat/wavdec.c index 8a7f84b..8651372 100644 --- a/libavformat/wavdec.c +++ b/libavformat/wavdec.c @@ -248,7 +248,7 @@