Commit 6e046750 authored by Michael Niedermayer's avatar Michael Niedermayer

big endian compile fix by ("Ronald S. Bultje" <R dot S dot Bultje at students dot uu dot nl>)

Originally committed as revision 2873 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent a2faa401
...@@ -624,10 +624,10 @@ ebml_read_float (MatroskaDemuxContext *matroska, ...@@ -624,10 +624,10 @@ ebml_read_float (MatroskaDemuxContext *matroska,
if (size == 4) { if (size == 4) {
float f; float f;
while (size-- > 0)
#ifdef WORDS_BIGENDIAN #ifdef WORDS_BIGENDIAN
f = * (float *) data; ((uint8_t *) &f)[3 - size] = get_byte(pb);
#else #else
while (size-- > 0)
((uint8_t *) &f)[size] = get_byte(pb); ((uint8_t *) &f)[size] = get_byte(pb);
#endif #endif
...@@ -635,10 +635,10 @@ ebml_read_float (MatroskaDemuxContext *matroska, ...@@ -635,10 +635,10 @@ ebml_read_float (MatroskaDemuxContext *matroska,
} else { } else {
double d; double d;
while (size-- > 0)
#ifdef WORDS_BIGENDIAN #ifdef WORDS_BIGENDIAN
d = * (double *) data; ((uint8_t *) &d)[7 - size] = get_byte(pb);
#else #else
while (size-- > 0)
((uint8_t *) &d)[size] = get_byte(pb); ((uint8_t *) &d)[size] = get_byte(pb);
#endif #endif
......
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