VirtualBox

Changeset 80966 in vbox


Ignore:
Timestamp:
Sep 24, 2019 9:58:55 AM (5 years ago)
Author:
vboxsync
Message:

Shared Clipboard/Win: Don't bail out if we don't have the new clipboard API available.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/GuestHost/SharedClipboard/clipboard-win.cpp

    r80918 r80966  
    160160    {
    161161        /* Check that new Clipboard API is available. */
    162         rc = SharedClipboardWinCheckAndInitNewAPI(&pWinCtx->newAPI);
    163         if (RT_SUCCESS(rc))
    164         {
    165             pWinCtx->hWnd                 = NULL;
    166             pWinCtx->hWndClipboardOwnerUs = NULL;
    167             pWinCtx->hWndNextInChain      = NULL;
    168         }
     162        SharedClipboardWinCheckAndInitNewAPI(&pWinCtx->newAPI);
     163        /* Do *not* check the rc, as the call might return VERR_SYMBOL_NOT_FOUND is the new API isn't available. */
     164
     165        pWinCtx->hWnd                 = NULL;
     166        pWinCtx->hWndClipboardOwnerUs = NULL;
     167        pWinCtx->hWndNextInChain      = NULL;
    169168    }
    170169
     
    194193 * the new clipboard API.
    195194 *
    196  * @returns VBox status code.
     195 * @returns VBox status code, or VERR_SYMBOL_NOT_FOUND if the new API is not available.
    197196 * @param   pAPI                Where to store the retrieved function pointers.
    198197 *                              Will be set to NULL if the new API is not available.
     
    215214    if (RT_SUCCESS(rc))
    216215    {
    217         LogFunc(("New Clipboard API enabled\n"));
     216        LogRel(("Shared Clipboard: New Clipboard API enabled\n"));
    218217    }
    219218    else
    220219    {
    221220        RT_BZERO(pAPI, sizeof(SHCLWINAPINEW));
    222         LogFunc(("New Clipboard API not available; rc=%Rrc\n", rc));
    223     }
    224 
     221        LogRel(("Shared Clipboard: New Clipboard API not available (%Rrc)\n", rc));
     222    }
     223
     224    LogFlowFuncLeaveRC(rc);
    225225    return rc;
    226226}
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