From 4fab5040a65c5218c42be283820aaf0184df9391 Mon Sep 17 00:00:00 2001 From: "R. Timothy Edwards" Date: Sun, 2 Aug 2026 17:40:32 -0400 Subject: [PATCH] Added a hack to prevent a port from being added to the node kill list in "extresist". This was previously done when a device terminal could not be found and defaults to its original node name, but apparently the port itself can get disconnected from the rest of the net, which needs to be thoroughly investigated. See the issue that was posted in the netgen issue tracker (issue #108) by Simon Dorrer. --- resis/ResPrint.c | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/resis/ResPrint.c b/resis/ResPrint.c index 91eeef41..4ead1835 100644 --- a/resis/ResPrint.c +++ b/resis/ResPrint.c @@ -245,12 +245,22 @@ ResPrintExtNode(outextfile, nodelist, node) /* extraction, but this prevents magic from generating an invalid */ /* netlist. */ - if (node->status & DONTKILL) - if (DoKillNode == TRUE) - { - DoKillNode = FALSE; - NeedFix = TRUE; - } + if (DoKillNode && (node->status & DONTKILL)) + { + DoKillNode = FALSE; + NeedFix = TRUE; + } + + /* If somehow a node which is a port is still being marked as killed, + * treat the same way as above for device terminals that failed to + * extract. + */ + + if (DoKillNode && (node->status & PORTNODE)) + { + DoKillNode = FALSE; + NeedFix = TRUE; + } if ((ResOptionsFlags & ResOpt_DoExtFile) && DoKillNode) fprintf(outextfile, "killnode \"%s\"\n", nodename);