VirtualBox

Changeset 63642 in vbox


Ignore:
Timestamp:
Aug 25, 2016 3:43:45 PM (9 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
110369
Message:

microatl.h: InternalRelease should check VBOX_STRICT not DEBUG. Use AssertMsg instead of AssertMsgFailed. Text was also ambiguous.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/VBox/com/microatl.h

    r63638 r63642  
    2727#define ___VBox_com_microatl_h
    2828
     29#include <VBox/cdefs.h> /* VBOX_STRICT */
    2930#include <iprt/assert.h>
    3031#include <iprt/critsect.h>
     
    901902    ULONG InternalRelease()
    902903    {
    903 #ifdef DEBUG
     904#ifdef VBOX_STRICT
    904905        LONG c = ThreadModel::Decrement(&m_iRef);
    905         if (c < -(LONG_MAX / 2))
    906         {
    907             AssertMsgFailed(("Release called on object which has been already released\n"));
    908         }
     906        AssertMsg(c >= -(LONG_MAX / 2), /* See  ~CComObjectNoLock, ~CComObject & ~CComAggObject. */
     907                  ("Release called on object which has been already destroyed!\n"));
    909908        return c;
    910909#else
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