aboutsummaryrefslogtreecommitdiffstats
path: root/libswscale
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-09-17 17:21:13 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-09-17 17:21:13 +0200
commitaec91de549612ba493f1b7c569a23c116ccd757a (patch)
tree58382f68bc1d079626130d159bb75458a49c5b7b /libswscale
parent09887096734eabaac5454b3fb5e4489457ac9434 (diff)
downloadffmpeg-aec91de549612ba493f1b7c569a23c116ccd757a.tar.gz
swscale/utils: Allow sws_setColorspaceDetails() to use the tables from sws_getColorspaceDetails()
Previously this would have lead to a memcpy(a,a) which violates the requirement of non overlapping src and dst. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libswscale')
-rw-r--r--libswscale/utils.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libswscale/utils.c b/libswscale/utils.c
index 497d369c81..0d4fc3fc28 100644
--- a/libswscale/utils.c
+++ b/libswscale/utils.c
@@ -960,8 +960,8 @@ int sws_setColorspaceDetails(struct SwsContext *c, const int inv_table[4],
{
const AVPixFmtDescriptor *desc_dst;
const AVPixFmtDescriptor *desc_src;
- memcpy(c->srcColorspaceTable, inv_table, sizeof(int) * 4);
- memcpy(c->dstColorspaceTable, table, sizeof(int) * 4);
+ memmove(c->srcColorspaceTable, inv_table, sizeof(int) * 4);
+ memmove(c->dstColorspaceTable, table, sizeof(int) * 4);
handle_formats(c);
desc_dst = av_pix_fmt_desc_get(c->dstFormat);