VirtualBox

Changeset 62965 in vbox for trunk/src/VBox/Devices/Audio


Ignore:
Timestamp:
Aug 4, 2016 9:57:20 AM (8 years ago)
Author:
vboxsync
Message:

Devices: warnings

Location:
trunk/src/VBox/Devices/Audio
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Audio/AudioMixBuffer.cpp

    r62909 r62965  
    583583
    584584/** Dummy conversion used when the source is muted. */
    585 static DECLCALLBACK(uint32_t) audioMixBufConvFromSilence(PPDMAUDIOSAMPLE paDst, const void *pvSrc,
    586                                                          uint32_t cbSrc, PCPDMAUDMIXBUFCONVOPTS pOpts)
    587 {
     585static DECLCALLBACK(uint32_t)
     586audioMixBufConvFromSilence(PPDMAUDIOSAMPLE paDst, const void *pvSrc, uint32_t cbSrc, PCPDMAUDMIXBUFCONVOPTS pOpts)
     587{
     588    RT_NOREF(cbSrc, pvSrc);
     589
    588590    /* Internally zero always corresponds to silence. */
    589591    RT_BZERO(paDst, pOpts->cSamples * sizeof(paDst[0]));
     
    648650        }
    649651    }
    650 
    651     return NULL;
     652    /* not reached */
    652653}
    653654
     
    709710        }
    710711    }
    711 
    712     return NULL;
     712    /* not reached */
    713713}
    714714
     
    10191019#endif
    10201020
    1021     uint32_t cSrcToRead;
     1021    uint32_t cSrcToRead = 0;
    10221022    uint32_t cSrcRead;
    10231023
  • trunk/src/VBox/Devices/Audio/AudioMixer.cpp

    r62605 r62965  
    129129int AudioMixerCreate(const char *pszName, uint32_t fFlags, PAUDIOMIXER *ppMixer)
    130130{
     131    RT_NOREF(fFlags);
    131132    AssertPtrReturn(pszName, VERR_INVALID_POINTER);
    132133    /** @todo Add fFlags validation. */
     
    176177void AudioMixerDebug(PAUDIOMIXER pMixer, PCDBGFINFOHLP pHlp, const char *pszArgs)
    177178{
     179    RT_NOREF(pszArgs);
    178180    PAUDMIXSINK pSink;
    179181    unsigned    iSink = 0;
     
    491493        /* Increase the stream's reference count to let others know
    492494         * we're reyling on it to be around now. */
    493         pConn->pfnStreamAddRef(pConn, pStream);
     495        pConn->pfnStreamRetain(pConn, pStream);
    494496    }
    495497
     
    763765int AudioMixerSinkRead(PAUDMIXSINK pSink, AUDMIXOP enmOp, void *pvBuf, uint32_t cbBuf, uint32_t *pcbRead)
    764766{
     767    RT_NOREF(enmOp);
    765768    AssertPtrReturn(pSink, VERR_INVALID_POINTER);
    766769    AssertPtrReturn(pvBuf, VERR_INVALID_POINTER);
     
    10801083        AssertPtr(pConn);
    10811084
    1082         uint32_t cPlayed   = 0;
    10831085        uint32_t cCaptured = 0;
    10841086
     
    12571259int AudioMixerSinkWrite(PAUDMIXSINK pSink, AUDMIXOP enmOp, const void *pvBuf, uint32_t cbBuf, uint32_t *pcbWritten)
    12581260{
     1261    RT_NOREF(enmOp);
    12591262    AssertPtrReturn(pSink, VERR_INVALID_POINTER);
    12601263    /* pcbWritten is optional. */
     
    13201323int AudioMixerStreamCtl(PAUDMIXSTREAM pMixStream, PDMAUDIOSTREAMCMD enmCmd, uint32_t fCtl)
    13211324{
     1325    RT_NOREF(fCtl);
    13221326    AssertPtrReturn(pMixStream, VERR_INVALID_POINTER);
    13231327    /** @todo Validate fCtl. */
  • trunk/src/VBox/Devices/Audio/DevSB16.cpp

    r62605 r62965  
    21532153            rc2 = pDrv->pConnector->pfnStreamCreate(pDrv->pConnector, &CfgHost, pCfg, &pDrv->Out.pStream);
    21542154            if (RT_SUCCESS(rc2))
    2155                 pDrv->pConnector->pfnStreamAddRef(pDrv->pConnector, pDrv->Out.pStream);
     2155                pDrv->pConnector->pfnStreamRetain(pDrv->pConnector, pDrv->Out.pStream);
    21562156        }
    21572157
  • trunk/src/VBox/Devices/Audio/DrvAudio.cpp

    r62607 r62965  
    785785
    786786/**
    787  * @interface_method_impl{PDMIAUDIOCONNECTOR,pfnStreamAddRef}
    788  */
    789 static DECLCALLBACK(uint32_t) drvAudioStreamAddRef(PPDMIAUDIOCONNECTOR pInterface, PPDMAUDIOSTREAM pStream)
    790 {
    791    AssertPtrReturn(pInterface, VERR_INVALID_POINTER);
    792    AssertPtrReturn(pStream,    VERR_INVALID_POINTER);
     787 * @interface_method_impl{PDMIAUDIOCONNECTOR,pfnStreamRetain}
     788 */
     789static DECLCALLBACK(uint32_t) drvAudioStreamRetain(PPDMIAUDIOCONNECTOR pInterface, PPDMAUDIOSTREAM pStream)
     790{
     791   AssertPtrReturn(pInterface, UINT32_MAX);
     792   AssertPtrReturn(pStream,    UINT32_MAX);
    793793
    794794   NOREF(pInterface);
     
    802802static DECLCALLBACK(uint32_t) drvAudioStreamRelease(PPDMIAUDIOCONNECTOR pInterface, PPDMAUDIOSTREAM pStream)
    803803{
    804    AssertPtrReturn(pInterface, VERR_INVALID_POINTER);
    805    AssertPtrReturn(pStream,    VERR_INVALID_POINTER);
     804   AssertPtrReturn(pInterface, UINT32_MAX);
     805   AssertPtrReturn(pStream,    UINT32_MAX);
    806806
    807807   NOREF(pInterface);
     
    18681868    AssertPtrReturn(pVol,       VERR_INVALID_POINTER);
    18691869
    1870     PDRVAUDIO pThis = PDMIAUDIOCONNECTOR_2_DRVAUDIO(pInterface);
    1871 
    18721870    LogFlowFunc(("%s: volL=%RU32, volR=%RU32, fMute=%RTbool\n", pStream->szName, pVol->uLeft, pVol->uRight, pVol->fMuted));
    18731871
     
    21502148    pThis->IAudioConnector.pfnStreamCreate      = drvAudioStreamCreate;
    21512149    pThis->IAudioConnector.pfnStreamDestroy     = drvAudioStreamDestroy;
    2152     pThis->IAudioConnector.pfnStreamAddRef      = drvAudioStreamAddRef;
     2150    pThis->IAudioConnector.pfnStreamRetain      = drvAudioStreamRetain;
    21532151    pThis->IAudioConnector.pfnStreamRelease     = drvAudioStreamRelease;
    21542152    pThis->IAudioConnector.pfnStreamControl     = drvAudioStreamControl;
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette