GNOME Bugzilla – Bug 572256
gst/avi/gstavidemux.c: Alignment trap in gst_avi_demux_parse_odml() line 1270 (from git)
Last modified: 2009-02-22 17:34:47 UTC
Hi, I am running gstreamer-0.10.21 with gst-plugin-good-0.10.10 on a da-vinci dm6446 platform (arm9 processor). I have had a crash (actually it crashes every time) on this line (in gst_avi_demux_parse_odml()): dmlh.totalframes = GUINT32_FROM_LE (_dmlh->totalframes); It seems like _dmlh is rounded to 2 while acceeding an integer must have a rounded to 4 address. Replacing this line by: dmlh.totalframes = GST_READ_UINT32_LE (&_dmlh->totalframes); fixes the problem (GST_READ_UINT32_LE reads bytes by bytes and is thus correct on unaligned address). Is it the correct way to fix it or is there some other issue in my setup ?
Yes, that's the correct way to fix it. I'll commit this change after -good 0.10.14 is released, thanks :)
Fixed in GIT (and another alignment issue). If you find more issues like this please report them :) commit 6756475fd3af29844a77bcb08d9943070daf6f9e Author: Sebastian Dröge <sebastian.droege@collabora.co.uk> Date: Sun Feb 22 18:32:02 2009 +0100 avidemux: Fix alignment issues by using GST_READ_* Reading integers from random memory addresses will result in SIGBUS on some architectures if the memory address is not correctly aligned. This can happen at two places in avidemux so we should use GST_READ_UINT32_LE and friends here. Fixes bug #572256.