Check for minimal size in non-anchored Contact CTOR.

This commit is contained in:
Jean-Paul Chaput 2023-07-14 12:28:08 +02:00
parent b734d61a00
commit 7b304da14b
1 changed files with 3 additions and 0 deletions

View File

@ -118,6 +118,9 @@ Contact::Contact(Net* net, const Layer* layer, DbU::Unit x, DbU::Unit y, DbU::Un
{
if (not _layer)
throw Error("Contact::Contact(): Can't create " + _TName("Contact") + ", NULL layer.");
if ( _width < _layer->getMinimalSize() ) _width = _layer->getMinimalSize();
if ( _height < _layer->getMinimalSize() ) _height = _layer->getMinimalSize();
}
Contact::Contact(Net* net, Component* anchor, const Layer* layer, DbU::Unit dx, DbU::Unit dy, DbU::Unit width, DbU::Unit height)