From 993497438b6969b5cca94a566096895f3494af4d Mon Sep 17 00:00:00 2001 From: Istvan Csomortani Date: Thu, 30 May 2019 07:46:14 +0100 Subject: [PATCH] adi_project:adi_project_run: Check if $num_reg exist --- projects/scripts/adi_project.tcl | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/projects/scripts/adi_project.tcl b/projects/scripts/adi_project.tcl index f9c9fe260..f97530974 100644 --- a/projects/scripts/adi_project.tcl +++ b/projects/scripts/adi_project.tcl @@ -249,10 +249,14 @@ proc adi_project_run {project_name} { # Look for undefined clocks which do not show up in the timing summary set timing_check [check_timing -override_defaults no_clock -no_header -return_string] if {[regexp { (\d+) register} $timing_check -> num_regs]} { - if {$num_regs > 0} { - puts "CRITICAL WARNING: There are $num_regs registers with no clocks !!! See no_clock.log for details." - check_timing -override_defaults no_clock -verbose -file no_clock.log + + if {[info exist num_regs]} { + if {$num_regs > 0} { + puts "CRITICAL WARNING: There are $num_regs registers with no clocks !!! See no_clock.log for details." + check_timing -override_defaults no_clock -verbose -file no_clock.log + } } + } else { puts "CRITICAL WARNING: The search for undefined clocks failed !!!" }