diff --git a/libavformat/mov.c b/libavformat/mov.c
index 651c685..d081f4f 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -1027,8 +1027,10 @@ int ff_mov_read_stsd_entries(MOVContext *c, AVIOContext *pb, int entries)
             if (len < 31)
                 avio_skip(pb, 31 - len);
             /* codec_tag YV12 triggers an UV swap in rawdec.c */
-            if (!memcmp(st->codec->codec_name, "Planar Y'CbCr 8-bit 4:2:0", 25))
+            if (!memcmp(st->codec->codec_name, "Planar Y'CbCr 8-bit 4:2:0", 25)){
                 st->codec->codec_tag=MKTAG('I', '4', '2', '0');
+                st->codec->width &= ~1;
+            }
 
             st->codec->bits_per_coded_sample = avio_rb16(pb); /* depth */
             st->codec->color_table_id = avio_rb16(pb); /* colortable id */
