projects
/
platform
/
upstream
/
libav.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bb68f8a
)
Fix MPEG video packetization for RTP
author
Luca Abeni
<lucabe72@email.it>
Thu, 10 Jul 2008 07:40:54 +0000
(07:40 +0000)
committer
Luca Abeni
<lucabe72@email.it>
Thu, 10 Jul 2008 07:40:54 +0000
(07:40 +0000)
Originally committed as revision 14149 to svn://svn.ffmpeg.org/ffmpeg/trunk
libavformat/rtp_mpv.c
patch
|
blob
|
history
diff --git
a/libavformat/rtp_mpv.c
b/libavformat/rtp_mpv.c
index 061eb351924fb1bbd525e4ff7e36e4e1e258762e..2c67f058a09c3c26bf3f2e8f431beed1286208db 100644
(file)
--- a/
libavformat/rtp_mpv.c
+++ b/
libavformat/rtp_mpv.c
@@
-66,7
+66,7
@@
void ff_rtp_send_mpegvideo(AVFormatContext *s1, const uint8_t *buf1, int size)
begin_of_sequence = 1;
}
- if (r - buf1
<
len) {
+ if (r - buf1
- 4 <=
len) {
/* The current slice fits in the packet */
if (begin_of_slice == 0) {
/* no slice at the beginning of the packet... */
@@
-76,7
+76,7
@@
void ff_rtp_send_mpegvideo(AVFormatContext *s1, const uint8_t *buf1, int size)
}
r1 = r;
} else {
- if (
r - r1 < max_packet_size - 4
) {
+ if (
(r1 - buf1 > 4) && (r - r1 < max_packet_size)
) {
len = r1 - buf1 - 4;
end_of_slice = 1;
}