[FFmpeg-cvslog] rtmp: Return proper error code in handle_server_bw

Samuel Pitoiset git at videolan.org
Thu Jul 26 21:55:14 CEST 2012


ffmpeg | branch: master | Samuel Pitoiset <samuel.pitoiset at gmail.com> | Wed Jul 25 20:51:10 2012 +0200| [be8f949219c03e6bf93d8d563ef33b8ad4faa1e9] | committer: Martin Storsjö

rtmp: Return proper error code in handle_server_bw

Signed-off-by: Martin Storsjö <martin at martin.st>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=be8f949219c03e6bf93d8d563ef33b8ad4faa1e9
---

 libavformat/rtmpproto.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/rtmpproto.c b/libavformat/rtmpproto.c
index be61074..5ac60d2 100644
--- a/libavformat/rtmpproto.c
+++ b/libavformat/rtmpproto.c
@@ -946,7 +946,7 @@ static int handle_server_bw(URLContext *s, RTMPPacket *pkt)
     if (rt->server_bw <= 0) {
         av_log(s, AV_LOG_ERROR, "Incorrect server bandwidth %d\n",
                rt->server_bw);
-        return AVERROR(EINVAL);
+        return AVERROR_INVALIDDATA;
     }
     av_log(s, AV_LOG_DEBUG, "Server bandwidth = %d\n", rt->server_bw);
 



More information about the ffmpeg-cvslog mailing list