VirtualBox

Changeset 78941 in vbox for trunk/src/VBox/Main


Ignore:
Timestamp:
Jun 3, 2019 7:05:16 PM (6 years ago)
Author:
vboxsync
Message:

Main/HostDnsService: Fixed a memory leak; was not deleting the monitor implementation instance on uninit.

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

Legend:

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

    r77993 r78941  
    312312    if (m)
    313313    {
    314         m->pMonitorImpl->uninit();
     314        if (m->pMonitorImpl)
     315        {
     316            m->pMonitorImpl->uninit();
     317
     318            delete m->pMonitorImpl;
     319            m->pMonitorImpl = NULL;
     320        }
    315321
    316322        delete m;
  • trunk/src/VBox/Main/src-server/HostDnsService.h

    r78030 r78941  
    6868    virtual void uninit(void);
    6969
     70    virtual ~HostDnsServiceBase();
     71
    7072protected:
    7173
    7274    explicit HostDnsServiceBase(bool fThreaded = false);
    73     virtual ~HostDnsServiceBase();
    7475
    7576    void setInfo(const HostDnsInformation &);
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