aboutsummaryrefslogtreecommitdiffhomepage
path: root/libao2
diff options
context:
space:
mode:
authorGravatar reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2009-03-06 19:07:50 +0000
committerGravatar reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2009-03-06 19:07:50 +0000
commit6067203caba5f1bb91bebd73c89e82056aa8d1c2 (patch)
tree08041a7f607e81a26d36f6daf75673ff38e764fa /libao2
parent6040a6f3ea230648783fbcd450b025feab52de57 (diff)
get rid of full_buffers variable, if the check it is used for is triggered
something is seriously wrong and the ao will not work right anyway. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28855 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libao2')
-rw-r--r--libao2/ao_win32.c9
1 files changed, 0 insertions, 9 deletions
diff --git a/libao2/ao_win32.c b/libao2/ao_win32.c
index ed95f2378b..2072ed0404 100644
--- a/libao2/ao_win32.c
+++ b/libao2/ao_win32.c
@@ -87,7 +87,6 @@ static const int channel_mask[] = {
static WAVEHDR* waveBlocks; //pointer to our ringbuffer memory
static HWAVEOUT hWaveOut; //handle to the waveout device
static unsigned int buf_write=0;
-static volatile int full_buffers=0;
static volatile int buffered_bytes=0;
@@ -106,12 +105,7 @@ static void CALLBACK waveOutProc(HWAVEOUT hWaveOut,UINT uMsg,DWORD dwInstance,
{
if(uMsg != WOM_DONE)
return;
- if (full_buffers) {
buffered_bytes-=BUFFER_SIZE;
- --full_buffers;
- } else {
- buffered_bytes=0;
- }
}
// to set/get/query special features/parameters
@@ -239,7 +233,6 @@ static int init(int rate,int channels,int format,int flags)
buffer += BUFFER_SIZE;
}
buf_write=0;
- full_buffers=0;
buffered_bytes=0;
return 1;
@@ -263,7 +256,6 @@ static void reset(void)
{
waveOutReset(hWaveOut);
buf_write=0;
- full_buffers=0;
buffered_bytes=0;
}
@@ -299,7 +291,6 @@ static int write_waveOutBuffer(unsigned char* data,int len){
x=BUFFER_SIZE;
if(x>len) x=len;
fast_memcpy(current->lpData,data+len2,x);
- full_buffers++;
len2+=x; len-=x;
buffered_bytes+=x;
//prepare header and write data to device