Browse Source

Fixed a bug in the unit tests without JUCE_STRICT_REFCOUNTEDPOINTER

tags/2021-05-28
Tom Poole 7 years ago
parent
commit
608f7bc36c
1 changed files with 5 additions and 0 deletions
  1. +5
    -0
      modules/juce_core/containers/juce_ReferenceCountedArray.cpp

+ 5
- 0
modules/juce_core/containers/juce_ReferenceCountedArray.cpp View File

@@ -82,7 +82,12 @@ public:
expectEquals (derivedObject->getReferenceCount(), 1);
baseArray.add (baseObjectPtr);
#if JUCE_STRICT_REFCOUNTEDPOINTER
baseArray.add (derivedObjectPtr);
#else
baseArray.add (derivedObjectPtr.get());
#endif
for (auto o : baseArray)
expectEquals (o->getReferenceCount(), 2);


Loading…
Cancel
Save