From 105885402f39c74adb54faee3eb508fb03b9b9f3 Mon Sep 17 00:00:00 2001 From: Michael Witten Date: Fri, 15 Feb 2008 21:40:12 -0500 Subject: [PATCH] ivlpp: Fixed include_path inconsistency Discussions online and "standards" documents are never conclusive, but the code that was present suggests that iverilog adopts the sane practice of resolving relative paths against the directory of the file that is currently being processed. Unfortunately, when a relative path is made absolute, the code forgot to update the necessary include_stack_t object. This has now been fixed. Signed-off-by: Michael Witten --- ivlpp/lexor.lex | 1 + 1 file changed, 1 insertion(+) diff --git a/ivlpp/lexor.lex b/ivlpp/lexor.lex index 92c20e268..83bfb503a 100644 --- a/ivlpp/lexor.lex +++ b/ivlpp/lexor.lex @@ -1195,6 +1195,7 @@ static void do_include() sprintf(path, "%s/%s", include_dir[idx], standby->path); standby->file = fopen(path, "r"); if (standby->file) { + standby->path = strdup(path); if(depend_file) { fprintf(depend_file, "%s\n", path); }