Browse Source

Fixed a potential crash in the new Android exporter

tags/2021-05-28
hogliux 8 years ago
parent
commit
1ed0051d74
1 changed files with 10 additions and 4 deletions
  1. +10
    -4
      extras/Projucer/Source/Project Saving/jucer_ProjectExport_Android.h

+ 10
- 4
extras/Projucer/Source/Project Saving/jucer_ProjectExport_Android.h View File

@@ -383,11 +383,17 @@ private:
if (! first)
{
const auto& cfg = dynamic_cast<const AndroidBuildConfiguration&> (* getConfiguration(0));
mo << "ELSE(JUCE_BUILD_CONFIGFURATION MATCHES \"" << cfg.getProductFlavourCMakeIdentifier() <<"\")" << newLine;
mo << " MESSAGE( FATAL_ERROR \"No matching build-configuration found.\" )" << newLine;
mo << "ENDIF(JUCE_BUILD_CONFIGFURATION MATCHES \"" << cfg.getProductFlavourCMakeIdentifier() <<"\")" << newLine << newLine;
ProjectExporter::BuildConfiguration::Ptr config (getConfiguration(0));
if (config)
{
if (const auto* cfg = dynamic_cast<const AndroidBuildConfiguration*> (config.get()))
{
mo << "ELSE(JUCE_BUILD_CONFIGFURATION MATCHES \"" << cfg->getProductFlavourCMakeIdentifier() <<"\")" << newLine;
mo << " MESSAGE( FATAL_ERROR \"No matching build-configuration found.\" )" << newLine;
mo << "ENDIF(JUCE_BUILD_CONFIGFURATION MATCHES \"" << cfg->getProductFlavourCMakeIdentifier() <<"\")" << newLine << newLine;
}
}
}
}


Loading…
Cancel
Save