mirror of https://github.com/mpv-player/mpv
cdda: endianness fix
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@11653 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
424cd89dc8
commit
d984734abd
|
@ -5,6 +5,7 @@
|
|||
#include "stream.h"
|
||||
#include "../m_option.h"
|
||||
#include "../m_struct.h"
|
||||
#include "../bswap.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
@ -254,6 +255,11 @@ static int fill_buffer(stream_t* s, char* buffer, int max_len) {
|
|||
|
||||
buf = paranoia_read(p->cdp,cdparanoia_callback);
|
||||
|
||||
#ifdef WORDS_BIGENDIAN
|
||||
for(i=0;i<CD_FRAMESIZE_RAW/2;i++)
|
||||
buf[i]=le2me_16(buf[i]);
|
||||
#endif
|
||||
|
||||
p->sector++;
|
||||
s->pos = p->sector*CD_FRAMESIZE_RAW;
|
||||
memcpy(buffer,buf,CD_FRAMESIZE_RAW);
|
||||
|
|
Loading…
Reference in New Issue