summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRuben Undheim <ruben.undheim@gmail.com>2018-12-20 09:52:33 +0100
committerRuben Undheim <ruben.undheim@gmail.com>2018-12-20 09:52:33 +0100
commit78a87ef8856ea7bbc4062c759811a799067b79e2 (patch)
tree119dd155047152b817aeb3d4efa0e147b9cf3bb3
parenta82303713af76c07cbc4d36c24702a929c78e81c (diff)
parent83c4115dc8e9c5b2dbaf1f3182cba81a0ea4f0d5 (diff)
Merge tag 'upstream/1.3.107'
Upstream version 1.3.107
-rw-r--r--VERSION2
-rw-r--r--output.c13
2 files changed, 9 insertions, 6 deletions
diff --git a/VERSION b/VERSION
index d97d48f..328a637 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-1.3.106
+1.3.107
diff --git a/output.c b/output.c
index 723aad4..4fe49a2 100644
--- a/output.c
+++ b/output.c
@@ -231,7 +231,7 @@ char *print_node_name(NODE node)
{
GATE g;
int i;
- static char *nodestr = NULL;
+ char *nodestr = NULL;
for (g = Nlgates; g; g = g->next) {
for (i = 0; i < g->nodes; i++) {
@@ -239,12 +239,15 @@ char *print_node_name(NODE node)
if (nodestr != NULL)
free(nodestr);
- nodestr = (char *)malloc(strlen(g->gatename)
- + strlen(g->node[i]) + 2);
- if (!strcmp(g->node[i], "pin"))
+ if (!strcmp(g->node[i], "pin")) {
+ nodestr = (char *)malloc(strlen(g->gatename) + 5);
sprintf(nodestr, "PIN/%s", g->gatename);
- else
+ }
+ else {
+ nodestr = (char *)malloc(strlen(g->gatename)
+ + strlen(g->node[i]) + 2);
sprintf(nodestr, "%s/%s", g->gatename, g->node[i]);
+ }
return nodestr;
}
}