[vlc-commits] commit: vod: use memcmp() (Pierre Ynard )
git at videolan.org
git at videolan.org
Tue Jun 15 19:44:28 CEST 2010
vlc/vlc-1.1 | branch: master | Pierre Ynard <linkfanel at yahoo.fr> | Mon Jun 14 23:10:57 2010 +0200| [61ac38d5fde5541d99c28ceeb1554504cf361ec2] | committer: Pierre Ynard
vod: use memcmp()
Port df301d6589de2662febe4cf408e4ecdcf3b589b9 to duplicated code
(cherry picked from commit 7820c6b276438390eac5b5a371659dc7cbafabfa)
Signed-off-by: Pierre Ynard <linkfanel at yahoo.fr>
> http://git.videolan.org/gitweb.cgi/vlc/vlc-1.1.git/?a=commit;h=61ac38d5fde5541d99c28ceeb1554504cf361ec2
---
modules/misc/rtsp.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/modules/misc/rtsp.c b/modules/misc/rtsp.c
index 266caa2..ef6a30d 100644
--- a/modules/misc/rtsp.c
+++ b/modules/misc/rtsp.c
@@ -584,7 +584,7 @@ static int MediaAddES( vod_t *p_vod, vod_media_t *p_media, es_format_t *p_fmt )
i_size = i_buffer;
for( i_offset = 4; i_offset+3 < i_buffer ; i_offset++)
{
- if( p_buffer[i_offset] == 0 && p_buffer[i_offset+1] == 0 && p_buffer[i_offset+2] == 0 && p_buffer[i_offset+3] == 1 )
+ if( !memcmp (p_buffer + i_offset, "\x00\x00\x00\x01", 4 ) )
{
/* we found another startcode */
i_size = i_offset;
More information about the vlc-commits
mailing list