From df9a52de6cb8e8a1003c55cf8b9b947d82b442c4 Mon Sep 17 00:00:00 2001 From: Tim Edwards Date: Sat, 23 May 2020 21:33:42 -0400 Subject: [PATCH] Corrected potential crash condition that can happen if there is one or more repeated "equiv" lines in a .ext file. This implies two ports with different names are connected, indicating probably a bad layout, but that's not a reason to have magic crash. --- extflat/EFbuild.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/extflat/EFbuild.c b/extflat/EFbuild.c index 0eac0168..115a5b8c 100644 --- a/extflat/EFbuild.c +++ b/extflat/EFbuild.c @@ -457,10 +457,14 @@ efBuildEquiv(def, nodeName1, nodeName2) EFStrToHN((HierName *) NULL, nodeName2)); return; } + else if (nn2->efnn_node == (EFNode *)NULL) + return; /* Repeated "equiv" statement */ /* If both names exist and are for different nodes, merge them */ if (nn1) { + if (nn1->efnn_node == (EFNode *)NULL) + return; /* Repeated "equiv" statement */ if (nn1->efnn_node != nn2->efnn_node) { if (efWarn)