diff options
author | Linqiang Pu <pulq.ustc@gmail.com> | 2010-01-10 10:06:55 -0300 |
---|---|---|
committer | Thiago Santos <thiago.sousa.santos@collabora.co.uk> | 2010-01-10 10:09:55 -0300 |
commit | d68c2d4ab93fca79d0d1a1ebadde91176359c7ed (patch) | |
tree | 4e6ea87bcd4a36aaa62925bbb56367b2874b62bb | |
parent | 67e5d76d08d09ccbf8e68fa5894ba9543d83e59b (diff) |
mpegdemux: fix allignment issue
Use GST_READ_UINT32_BE instead of GUINT32_FROM_BE to
fix int allignment issues on ARM
Fixes #606371
-rw-r--r-- | gst/mpegdemux/gstmpegdemux.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/gst/mpegdemux/gstmpegdemux.c b/gst/mpegdemux/gstmpegdemux.c index 5c5fe53d7..d80995ab7 100644 --- a/gst/mpegdemux/gstmpegdemux.c +++ b/gst/mpegdemux/gstmpegdemux.c @@ -1497,8 +1497,8 @@ gst_flups_demux_parse_pack_start (GstFluPSDemux * demux) /* skip start code */ data += 4; - scr1 = GUINT32_FROM_BE (*(guint32 *) data); - scr2 = GUINT32_FROM_BE (*(guint32 *) (data + 4)); + scr1 = GST_READ_UINT32_BE (data); + scr2 = GST_READ_UINT32_BE (data + 4); /* fixed length to begin with, start code and two scr values */ length = 8 + 4; @@ -1544,7 +1544,7 @@ gst_flups_demux_parse_pack_start (GstFluPSDemux * demux) to DTS/PTS, that also implies 1 tick rounding error */ data += 6; /* PMR:22 ! :2==11 ! reserved:5 ! stuffing_len:3 */ - next32 = (GUINT32_FROM_BE ((*(guint32 *) data))); + next32 = GST_READ_UINT32_BE (data); if (G_UNLIKELY ((next32 & 0x00000300) != 0x00000300)) goto lost_sync; @@ -2227,8 +2227,8 @@ gst_flups_demux_scan_ts (GstFluPSDemux * demux, const guint8 * data, /* skip start code */ data += 4; - scr1 = GUINT32_FROM_BE (*(guint32 *) data); - scr2 = GUINT32_FROM_BE (*(guint32 *) (data + 4)); + scr1 = GST_READ_UINT32_BE (data); + scr2 = GST_READ_UINT32_BE (data + 4); /* start parsing the stream */ if ((*data & 0xc0) == 0x40) { @@ -2260,7 +2260,7 @@ gst_flups_demux_scan_ts (GstFluPSDemux * demux, const guint8 * data, to DTS/PTS, that also implies 1 tick rounding error */ data += 6; /* PMR:22 ! :2==11 ! reserved:5 ! stuffing_len:3 */ - next32 = (GUINT32_FROM_BE ((*(guint32 *) data))); + next32 = GST_READ_UINT32_BE (data); if ((next32 & 0x00000300) != 0x00000300) goto beach; |