Commit 58c41799 authored by Michael Niedermayer's avatar Michael Niedermayer

lzo: fix memcpy_backptr() with 0 offset

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 1858a5c2
...@@ -137,7 +137,7 @@ static inline void memcpy_backptr(uint8_t *dst, int back, int cnt) { ...@@ -137,7 +137,7 @@ static inline void memcpy_backptr(uint8_t *dst, int back, int cnt) {
const uint8_t *src = &dst[-back]; const uint8_t *src = &dst[-back];
if (back == 1) { if (back == 1) {
memset(dst, *src, cnt); memset(dst, *src, cnt);
} else { } else if(back>0) {
#ifdef OUTBUF_PADDED #ifdef OUTBUF_PADDED
COPY2(dst, src); COPY2(dst, src);
COPY2(dst + 2, src + 2); COPY2(dst + 2, src + 2);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment