From a8a904180d2e1ca67799d72c01de8f66fd109918 Mon Sep 17 00:00:00 2001 From: Jean-Paul Chaput Date: Fri, 8 Nov 2019 00:18:23 +0100 Subject: [PATCH] In AllianceFramework::createCell(), handle non-existent library. --- crlcore/src/ccore/AllianceFramework.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/crlcore/src/ccore/AllianceFramework.cpp b/crlcore/src/ccore/AllianceFramework.cpp index 918b116b..0dda5683 100644 --- a/crlcore/src/ccore/AllianceFramework.cpp +++ b/crlcore/src/ccore/AllianceFramework.cpp @@ -495,8 +495,12 @@ namespace CRL { // The cell is not in the CATAL : add an entry. if ( state == NULL ) state = _catalog.getState ( name, true ); - if ( library == NULL ) + if ( library == NULL ) { + if (_libraries.empty()) + throw Error( "AllianceFramework::createCell(): Libraries are not set up, maybe an initialization problem." ); + library = _libraries[0]; + } if ( !state->getCell() ) { state->setPhysical ( true );