Changeset 82893 in vbox for trunk/src/VBox
- Timestamp:
- Jan 28, 2020 4:53:51 PM (5 years ago)
- Location:
- trunk/src/VBox/HostServices/SharedClipboard
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/HostServices/SharedClipboard/VBoxSharedClipboardSvc-win.cpp
r82881 r82893 188 188 *ppvData = pPayload ? pPayload->pvData : NULL; 189 189 *pcbData = pPayload ? pPayload->cbData : 0; 190 191 /* Detach the payload, as the caller then will own the data. */ 192 ShClEventPayloadDetach(&pCtx->pClient->EventSrc, idEvent); 193 /** 194 * @todo r=bird: The payload has already been detached, 195 * ShClEventPayloadDetach and ShClEventWait does the exact same 196 * thing, except for the extra waiting in the latter. 197 */ 198 } 199 190 } 191 192 ShClEventRelease(&pCtx->pClient->EventSrc, idEvent); 200 193 ShClEventUnregister(&pCtx->pClient->EventSrc, idEvent); 201 194 } -
trunk/src/VBox/HostServices/SharedClipboard/VBoxSharedClipboardSvc-x11.cpp
r82880 r82893 354 354 *ppv = pPayload ? pPayload->pvData : NULL; 355 355 *pcb = pPayload ? pPayload->cbData : 0; 356 357 /* Detach the payload, as the caller then will own the data. */358 ShClEventPayloadDetach(&pCtx->pClient->EventSrc, idEvent);359 356 } 360 357 358 ShClEventRelease(&pCtx->pClient->EventSrc, idEvent); 361 359 ShClEventUnregister(&pCtx->pClient->EventSrc, idEvent); 362 360 } -
trunk/src/VBox/HostServices/SharedClipboard/VBoxSharedClipboardSvc.cpp
r82889 r82893 1204 1204 int rc = VERR_NOT_SUPPORTED; 1205 1205 1206 SHCLEVENTID idEvent = NIL_SHCLEVENTID; 1207 1206 1208 while (fFormats) 1207 1209 { … … 1238 1240 RTCritSectEnter(&pClient->CritSect); 1239 1241 1240 const SHCLEVENTIDidEvent = ShClEventIdGenerateAndRegister(&pClient->EventSrc);1242 idEvent = ShClEventIdGenerateAndRegister(&pClient->EventSrc); 1241 1243 if (idEvent != NIL_SHCLEVENTID) 1242 1244 { … … 1273 1275 RTCritSectEnter(&pClient->CritSect); 1274 1276 1277 /* Retain the last event generated (in case there were multiple clipboard formats) 1278 * if we need to return the event ID to the caller. */ 1279 if (pidEvent) 1280 { 1281 ShClEventRetain(&pClient->EventSrc, idEvent); 1282 *pidEvent = idEvent; 1283 } 1284 1275 1285 shClSvcClientWakeup(pClient); 1276 1286 1277 1287 RTCritSectLeave(&pClient->CritSect); 1278 1288 } 1279 1280 /** @todo BUGBUG What to do with allocated events? Which one to return? */1281 1289 1282 1290 LogFlowFuncLeaveRC(rc);
Note:
See TracChangeset
for help on using the changeset viewer.