VirtualBox

Changeset 82451 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Dec 6, 2019 12:46:23 PM (5 years ago)
Author:
vboxsync
Message:

DevIchAc97: Put debug path on the heap rather than always grabbing ~4KB of state data for it. bugref:9218

File:
1 edited

Legend:

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

    r82377 r82451  
    516516    /** Whether debugging is enabled or not. */
    517517    bool                    fEnabled;
     518    bool                    afAlignment[7];
    518519    /** Path where to dump the debug output to.
    519520     *  Defaults to VBOX_AUDIO_DEBUG_DUMP_PCM_DATA_PATH. */
    520     char                    szOutPath[RTPATH_MAX];
     521    R3PTRTYPE(char *)       pszOutPath;
    521522} AC97STATEDEBUG;
    522523
     
    10891090
    10901091        char szPath[RTPATH_MAX];
    1091         int rc2 = DrvAudioHlpFileNameGet(szPath, sizeof(szPath), pThisCC->Dbg.szOutPath, szFile,
     1092        int rc2 = DrvAudioHlpFileNameGet(szPath, sizeof(szPath), pThisCC->Dbg.pszOutPath, szFile,
    10921093                                         0 /* uInst */, PDMAUDIOFILETYPE_WAV, PDMAUDIOFILENAME_FLAGS_NONE);
    10931094        AssertRC(rc2);
     
    11001101            RTStrPrintf(szFile, sizeof(szFile), "ac97DMAReadSD%RU8", pStream->u8SD);
    11011102
    1102         rc2 = DrvAudioHlpFileNameGet(szPath, sizeof(szPath), pThisCC->Dbg.szOutPath, szFile,
     1103        rc2 = DrvAudioHlpFileNameGet(szPath, sizeof(szPath), pThisCC->Dbg.pszOutPath, szFile,
    11031104                                     0 /* uInst */, PDMAUDIOFILETYPE_WAV, PDMAUDIOFILENAME_FLAGS_NONE);
    11041105        AssertRC(rc2);
     
    41414142                                N_("AC97 configuration error: failed to read debugging enabled flag as boolean"));
    41424143
    4143     rc = pHlp->pfnCFGMQueryStringDef(pCfg, "DebugPathOut", pThisCC->Dbg.szOutPath, sizeof(pThisCC->Dbg.szOutPath),
    4144                                      VBOX_AUDIO_DEBUG_DUMP_PCM_DATA_PATH);
     4144    rc = pHlp->pfnCFGMQueryStringAllocDef(pCfg, "DebugPathOut", &pThisCC->Dbg.pszOutPath, VBOX_AUDIO_DEBUG_DUMP_PCM_DATA_PATH);
    41454145    if (RT_FAILURE(rc))
    41464146        return PDMDEV_SET_ERROR(pDevIns, rc,
     
    41484148
    41494149    if (pThisCC->Dbg.fEnabled)
    4150         LogRel2(("AC97: Debug output will be saved to '%s'\n", pThisCC->Dbg.szOutPath));
     4150        LogRel2(("AC97: Debug output will be saved to '%s'\n", pThisCC->Dbg.pszOutPath));
    41514151
    41524152    /*
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