VirtualBox

Changeset 59541 in vbox for trunk/src/VBox/Devices


Ignore:
Timestamp:
Feb 1, 2016 12:02:21 PM (9 years ago)
Author:
vboxsync
Message:

DevIchHdaCodec.cpp: Initialize and check for pu32Addr in vrbProcSetStreamId().

File:
1 edited

Legend:

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

    r59503 r59541  
    20322032    *pResp = 0;
    20332033
    2034     uint32_t *pu32addr;
     2034    uint32_t *pu32Addr = NULL;
    20352035    if (hdaCodecIsDacNode(pThis, CODEC_NID(cmd)))
    2036         pu32addr = &pThis->paNodes[CODEC_NID(cmd)].dac.u32F06_param;
     2036        pu32Addr = &pThis->paNodes[CODEC_NID(cmd)].dac.u32F06_param;
    20372037    else if (hdaCodecIsAdcNode(pThis, CODEC_NID(cmd)))
    2038         pu32addr = &pThis->paNodes[CODEC_NID(cmd)].adc.u32F06_param;
     2038        pu32Addr = &pThis->paNodes[CODEC_NID(cmd)].adc.u32F06_param;
    20392039    else if (hdaCodecIsSpdifOutNode(pThis, CODEC_NID(cmd)))
    2040         pu32addr = &pThis->paNodes[CODEC_NID(cmd)].spdifout.u32F06_param;
     2040        pu32Addr = &pThis->paNodes[CODEC_NID(cmd)].spdifout.u32F06_param;
    20412041    else if (hdaCodecIsSpdifInNode(pThis, CODEC_NID(cmd)))
    2042         pu32addr = &pThis->paNodes[CODEC_NID(cmd)].spdifin.u32F06_param;
     2042        pu32Addr = &pThis->paNodes[CODEC_NID(cmd)].spdifin.u32F06_param;
    20432043    else if (hdaCodecIsReservedNode(pThis, CODEC_NID(cmd)))
    2044         pu32addr = &pThis->paNodes[CODEC_NID(cmd)].reserved.u32F06_param;
     2044        pu32Addr = &pThis->paNodes[CODEC_NID(cmd)].reserved.u32F06_param;
    20452045    else
    20462046        LogRel2(("HDA: Unhandled set stream ID command: 0x%x (Payload=%RU8, NID=0x%x [%RU8])\n",
    20472047                 cmd, CODEC_VERB_PAYLOAD8(cmd), CODEC_NID(cmd)));
    20482048
    2049     hdaCodecSetRegisterU8(pu32addr, cmd, 0);
     2049    if (pu32Addr)
     2050        hdaCodecSetRegisterU8(pu32Addr, cmd, 0);
     2051
    20502052    return VINF_SUCCESS;
    20512053}
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