Changeset 8562 in vbox for trunk/src/VBox
- Timestamp:
- May 5, 2008 10:53:40 AM (17 years ago)
- svn:sync-xref-src-repo-rev:
- 30476
- Location:
- trunk/src/VBox/Frontends/VBoxBFE
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxBFE/USBProxyService.cpp
r8539 r8562 307 307 308 308 309 #ifdef USBDEVICE_WITH_EVERYTHING310 /*static*/ void USBProxyService::freeInterfaceMembers (PUSBINTERFACE pIf, unsigned cIfs)311 {312 while (cIfs-- > 0)313 {314 RTMemFree (pIf->paEndpoints);315 pIf->paEndpoints = NULL;316 RTStrFree ((char *)pIf->pszDriver);317 pIf->pszDriver = NULL;318 RTStrFree ((char *)pIf->pszInterface);319 pIf->pszInterface = NULL;320 321 freeInterfaceMembers(pIf->paAlts, pIf->cAlts);322 RTMemFree(pIf->paAlts);323 pIf->paAlts = NULL;324 pIf->cAlts = 0;325 326 /* next */327 pIf++;328 }329 }330 #endif331 332 333 309 /*static*/ void USBProxyService::freeDevice (PUSBDEVICE pDevice) 334 310 { 335 #ifdef USBDEVICE_WITH_EVERYTHING336 PUSBCONFIG pCfg = pDevice->paConfigurations;337 unsigned cCfgs = pDevice->bNumConfigurations;338 while (cCfgs-- > 0)339 {340 freeInterfaceMembers (pCfg->paInterfaces, pCfg->bNumInterfaces);341 RTMemFree (pCfg->paInterfaces);342 pCfg->paInterfaces = NULL;343 pCfg->bNumInterfaces = 0;344 345 RTStrFree ((char *)pCfg->pszConfiguration);346 pCfg->pszConfiguration = NULL;347 348 /* next */349 pCfg++;350 }351 RTMemFree (pDevice->paConfigurations);352 pDevice->paConfigurations = NULL;353 #endif354 355 311 RTStrFree ((char *)pDevice->pszManufacturer); 356 312 pDevice->pszManufacturer = NULL; -
trunk/src/VBox/Frontends/VBoxBFE/USBProxyService.h
r8539 r8562 140 140 141 141 public: 142 #ifdef USBDEVICE_WITH_EVERYTHING143 /**144 * Free all the members of a USB interface returned by getDevice().145 *146 * @param pIf Pointer to the interface.147 * @param cIfs Number of consecutive interfaces pIf points to148 */149 static void freeInterfaceMembers (PUSBINTERFACE pIf, unsigned cIfs);150 #endif151 152 142 /** 153 143 * Free one USB device returned by getDevice().
Note:
See TracChangeset
for help on using the changeset viewer.