directsound: the size in TimeGet() is not an mtime_t
authorSteve Lhomme <robux4@ycbcr.xyz>
Mon, 7 May 2018 15:06:55 +0000 (17:06 +0200)
committerSteve Lhomme <robux4@ycbcr.xyz>
Thu, 14 Jun 2018 14:40:31 +0000 (16:40 +0200)
modules/audio_output/directsound.c

index df0bf51..b6e4573 100644 (file)
@@ -143,7 +143,7 @@ static HRESULT TimeGet( aout_stream_sys_t *sys, mtime_t *delay )
 {
     DWORD read, status;
     HRESULT hr;
-    mtime_t size;
+    ssize_t size;
 
     hr = IDirectSoundBuffer_GetStatus( sys->p_dsbuffer, &status );
     if( hr != DS_OK )
@@ -155,7 +155,7 @@ static HRESULT TimeGet( aout_stream_sys_t *sys, mtime_t *delay )
     if( hr != DS_OK )
         return hr;
 
-    size = (mtime_t)read - sys->i_last_read;
+    size = (ssize_t)read - sys->i_last_read;
 
     /* GetCurrentPosition cannot be trusted if the return doesn't change
      * Just return an error */