lefTech.c: fix: default value logic error

Looks like a logic bug, hiding behind this compiler warning

lefTech.c:507:21: warning: suggest parentheses around assignment used as truth value
lefTech.c:509:21: warning: suggest parentheses around assignment used as truth value

GCC14 -Wall cleanup series [-Wparentheses]
This commit is contained in:
Darryl L. Miles 2024-10-04 16:01:47 +01:00 committed by Tim Edwards
parent 4ea0f6a9b7
commit cebb1a5277
1 changed files with 2 additions and 2 deletions

View File

@ -504,9 +504,9 @@ LefTechSetDefaults()
}
else if (lefl->lefClass == CLASS_ROUTE)
{
if (lefl->info.route.width = -1)
if (lefl->info.route.width == -1)
lefl->info.route.width = DRCGetDefaultLayerWidth(lefl->type);
if (lefl->info.route.spacing = -1)
if (lefl->info.route.spacing == -1)
lefl->info.route.width = DRCGetDefaultLayerSpacing(lefl->type,
lefl->type);
}