VirtualBox

Changeset 85309 in vbox for trunk/src/VBox/Main/src-server


Ignore:
Timestamp:
Jul 13, 2020 12:56:56 PM (5 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
139287
Message:

Main: Try harder using the Utf8Str versions of the event stuff where possible. bugref:9790

Location:
trunk/src/VBox/Main/src-server
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/src-server/MachineImpl.cpp

    r85306 r85309  
    1385313853 *  @note Locks this object for reading.
    1385413854 */
    13855 HRESULT SessionMachine::i_onNATRedirectRuleChange(ULONG ulSlot, BOOL aNatRuleRemove, IN_BSTR aRuleName,
    13856                                                   NATProtocol_T aProto, IN_BSTR aHostIp, LONG aHostPort,
    13857                                                   IN_BSTR aGuestIp, LONG aGuestPort)
     13855HRESULT SessionMachine::i_onNATRedirectRuleChanged(ULONG ulSlot, BOOL aNatRuleRemove, const Utf8Str &aRuleName,
     13856                                                   NATProtocol_T aProto, const Utf8Str &aHostIp, LONG aHostPort,
     13857                                                   const Utf8Str &aGuestIp, LONG aGuestPort)
    1385813858{
    1385913859    LogFlowThisFunc(("\n"));
  • trunk/src/VBox/Main/src-server/NATEngineImpl.cpp

    r82968 r85309  
    326326
    327327    alock.release();
    328     mParent->i_onNATRedirectRuleChange(ulSlot, FALSE, Bstr(name).raw(), aProto, Bstr(r.strHostIP).raw(),
    329                                        r.u16HostPort, Bstr(r.strGuestIP).raw(), r.u16GuestPort);
     328    mParent->i_onNATRedirectRuleChanged(ulSlot, FALSE, name, aProto, r.strHostIP, r.u16HostPort, r.strGuestIP, r.u16GuestPort);
    330329    return S_OK;
    331330}
     
    350349    mParent->i_setModified(Machine::IsModified_NetworkAdapters);
    351350    alock.release();
    352     mParent->i_onNATRedirectRuleChange(ulSlot, TRUE, Bstr(aName).raw(), r.proto, Bstr(r.strHostIP).raw(),
    353                                        r.u16HostPort, Bstr(r.strGuestIP).raw(), r.u16GuestPort);
     351    mParent->i_onNATRedirectRuleChanged(ulSlot, TRUE, aName, r.proto, r.strHostIP, r.u16HostPort, r.strGuestIP, r.u16GuestPort);
    354352    return S_OK;
    355353}
  • trunk/src/VBox/Main/src-server/VirtualBoxImpl.cpp

    r85307 r85309  
    37233723 *  @note Doesn't lock any object.
    37243724 */
    3725 void VirtualBox::i_onNatRedirectChanged(const Guid &aMachineId, ULONG ulSlot, bool fRemove, IN_BSTR aName,
    3726                                         NATProtocol_T aProto, IN_BSTR aHostIp, uint16_t aHostPort,
    3727                                         IN_BSTR aGuestIp, uint16_t aGuestPort)
    3728 {
    3729     ::FireNATRedirectEvent(m->pEventSource, aMachineId.toUtf16().raw(), ulSlot, fRemove, aName, aProto, aHostIp,
     3725void VirtualBox::i_onNatRedirectChanged(const Guid &aMachineId, ULONG ulSlot, bool fRemove, const Utf8Str &aName,
     3726                                        NATProtocol_T aProto, const Utf8Str &aHostIp, uint16_t aHostPort,
     3727                                        const Utf8Str &aGuestIp, uint16_t aGuestPort)
     3728{
     3729    ::FireNATRedirectEvent(m->pEventSource, aMachineId.toString(), ulSlot, fRemove, aName, aProto, aHostIp,
    37303730                           aHostPort, aGuestIp, aGuestPort);
    37313731}
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette