From 620217b86080eab4d5f827ed07640d51deec9d56 Mon Sep 17 00:00:00 2001 From: susinxy Date: Sat, 1 Jan 2022 13:48:42 +0800 Subject: [PATCH] fix tech file load error with qflow --- utils/tech.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/utils/tech.c b/utils/tech.c index e6feaff1..a3529273 100644 --- a/utils/tech.c +++ b/utils/tech.c @@ -476,8 +476,13 @@ TechLoad(filename, initmask) /* If a non-standard extension was used, then honor it */ if ((dptr != NULL) && (*dptr != '\0')) + { tf = PaOpen(filename, "r", (char *)NULL, ".", SysLibPath, &realname); - else + /* If the honored file in not there, try the filename with the suffix */ + if (tf == (FILE *) NULL) + tf = PaOpen(filename, "r", suffix, ".", SysLibPath, &realname); + } + else tf = PaOpen(filename, "r", suffix, ".", SysLibPath, &realname); if (tf == (FILE *) NULL)