VirtualBox

Changeset 59630 in vbox


Ignore:
Timestamp:
Feb 10, 2016 1:05:39 PM (9 years ago)
Author:
vboxsync
Message:

Devices/GIMDev: Gracefully fail on invalid config of debug support (when GIM forces debugging but debug port CFGM is missing).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/GIMDev/GIMDev.cpp

    r58532 r59630  
    207207                LogRel(("GIMDev: LUN#%u: Debug port configured\n", GIMDEV_DEBUG_LUN));
    208208            else
     209            {
    209210                LogRel(("GIMDev: LUN#%u: No unit\n", GIMDEV_DEBUG_LUN));
    210         }
    211         else if (rc == VERR_PDM_NO_ATTACHED_DRIVER)
     211                rc = VERR_INTERNAL_ERROR_2;
     212            }
     213        }
     214        else
    212215        {
    213216            pThis->pDbgDrvBase = NULL;
    214             LogRel(("GIMDev: LUN#%u: No debug port configured\n", GIMDEV_DEBUG_LUN));
    215         }
    216         else
    217         {
    218             AssertLogRelMsgFailed(("GIMDev: LUN#%u: Failed to attach to driver on debug port. rc=%Rrc\n", GIMDEV_DEBUG_LUN, rc));
    219             /* Don't call VMSetError here as we assume that the driver already set an appropriate error */
    220             return rc;
     217            LogRel(("GIMDev: LUN#%u: No debug port configured! rc=%Rrc\n", GIMDEV_DEBUG_LUN, rc));
     218        }
     219
     220        if (!pDbgDrvStream)
     221        {
     222            Assert(rc != VINF_SUCCESS);
     223            return PDMDevHlpVMSetError(pDevIns, rc, RT_SRC_POS,
     224                                   N_("Debug port configuration expected when GIM configured with debugging support"));
    221225        }
    222226
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