VirtualBox

Ignore:
Timestamp:
Mar 9, 2010 9:05:57 PM (15 years ago)
Author:
vboxsync
Message:

Storage/VBoxHDD+DrvVD: implement framework for providing thread synchronization. Additionally some cleanup to resolve a few minor long-standing todos.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Storage/RawHDDCore.cpp

    r26291 r27232  
    55
    66/*
    7  * Copyright (C) 2006-2007 Sun Microsystems, Inc.
     7 * Copyright (C) 2006-2010 Sun Microsystems, Inc.
    88 *
    99 * This file is part of VirtualBox Open Source Edition (OSE), as
     
    141141                                                     pImage->pszFilename,
    142142                                                     uOpenFlags,
    143                                                      NULL, &pImage->pvStorage);
     143                                                     NULL,
     144                                                     pImage->pVDIfsDisk,
     145                                                     &pImage->pvStorage);
    144146#endif
    145147
     
    317319                          PCPDMMEDIAGEOMETRY pPCHSGeometry,
    318320                          PCPDMMEDIAGEOMETRY pLCHSGeometry,
    319                           PFNVMPROGRESS pfnProgress, void *pvUser,
     321                          PFNVDPROGRESS pfnProgress, void *pvUser,
    320322                          unsigned uPercentStart, unsigned uPercentSpan)
    321323{
     
    403405        if (pfnProgress)
    404406        {
    405             rc = pfnProgress(NULL /* WARNING! pVM=NULL  */,
    406                              uPercentStart + uOff * uPercentSpan * 98 / (cbSize * 100),
    407                              pvUser);
     407            rc = pfnProgress(pvUser,
     408                             uPercentStart + uOff * uPercentSpan * 98 / (cbSize * 100));
    408409            if (RT_FAILURE(rc))
    409410                goto out;
     
    413414
    414415    if (RT_SUCCESS(rc) && pfnProgress)
    415         pfnProgress(NULL /* WARNING! pVM=NULL  */,
    416                     uPercentStart + uPercentSpan * 98 / 100, pvUser);
     416        pfnProgress(pvUser, uPercentStart + uPercentSpan * 98 / 100);
    417417
    418418    pImage->cbSize = cbSize;
     
    422422out:
    423423    if (RT_SUCCESS(rc) && pfnProgress)
    424         pfnProgress(NULL /* WARNING! pVM=NULL  */,
    425                     uPercentStart + uPercentSpan, pvUser);
     424        pfnProgress(pvUser, uPercentStart + uPercentSpan);
    426425
    427426    if (RT_FAILURE(rc))
     
    548547    PRAWIMAGE pImage;
    549548
    550     PFNVMPROGRESS pfnProgress = NULL;
     549    PFNVDPROGRESS pfnProgress = NULL;
    551550    void *pvUser = NULL;
    552551    PVDINTERFACE pIfProgress = VDInterfaceGet(pVDIfsOperation,
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