1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-11 23:54:18 +00:00

Plugin Host: Fixed a potential crash when creating a new document

This commit is contained in:
hogliux 2017-08-16 10:52:12 +01:00
parent b7a7563a59
commit 39ce151636

View file

@ -849,8 +849,9 @@ void GraphEditorPanel::changeListenerCallback (ChangeBroadcaster*)
void GraphEditorPanel::updateComponents()
{
for (auto* child : getChildren())
if (auto* fc = dynamic_cast<FilterComponent*> (child))
auto children = getChildren();
for (auto child : children)
if (auto* fc = dynamic_cast<FilterComponent*> (static_cast<Component*> (child)))
fc->update();
for (int i = getNumChildComponents(); --i >= 0;)