[FFmpeg-devel] [PATCH 1/2] lavu: fix GET_UTF8 macro.
Nicolas George
nicolas.george at normalesup.org
Sun Apr 21 17:25:48 CEST 2013
Prevent 0xFE and 0xFF from being considered the start of
non-standard 7-bytes sequences. No noticeable effect on speed.
Signed-off-by: Nicolas George <nicolas.george at normalesup.org>
---
libavutil/common.h | 2 +-
libavutil/version.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
New version of the series, after the discussion with Reimar.
diff --git a/libavutil/common.h b/libavutil/common.h
index e303c25..13f2ffb 100644
--- a/libavutil/common.h
+++ b/libavutil/common.h
@@ -297,7 +297,7 @@ static av_always_inline av_const int av_popcount64_c(uint64_t x)
val= GET_BYTE;\
{\
uint32_t top = (val & 128) >> 1;\
- if ((val & 0xc0) == 0x80)\
+ if ((val & 0xc0) == 0x80 || val >= 0xFE)\
ERROR\
while (val & top) {\
int tmp= GET_BYTE - 128;\
diff --git a/libavutil/version.h b/libavutil/version.h
index e46e97c..abcdba8 100644
--- a/libavutil/version.h
+++ b/libavutil/version.h
@@ -76,7 +76,7 @@
#define LIBAVUTIL_VERSION_MAJOR 52
#define LIBAVUTIL_VERSION_MINOR 27
-#define LIBAVUTIL_VERSION_MICRO 100
+#define LIBAVUTIL_VERSION_MICRO 101
#define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \
LIBAVUTIL_VERSION_MINOR, \
--
1.7.10.4
More information about the ffmpeg-devel
mailing list