From c50367daa2f672ea696e6b68606cf39cf2e38d5f Mon Sep 17 00:00:00 2001 From: Todd Lyons Date: Mon, 3 Nov 2014 13:18:58 -0800 Subject: [PATCH] Fix uninitialized perl variable error output --- run_build.pl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/run_build.pl b/run_build.pl index 9e68d8d..40a63d6 100755 --- a/run_build.pl +++ b/run_build.pl @@ -562,8 +562,10 @@ elsif (!$from_source) $last_success_snap = find_last('success.snap'); $forcerun = 1 unless (defined($last_run_snap)); - # If config file changed, force a rebuild - ($current_config) = (stat $orig_dir.'/'.$buildconf)[9]; + # If config file changed, force a rebuild. This assumes that the config + # file is in the CWD, which may not always be true, so handle it by + # adding 1 to the value of last_config, which will force the rebuild. + ($current_config) = (stat $orig_dir.'/'.$buildconf)[9] || ($last_config+1); if ($current_config > $last_config) { $last_status = 0; -- 2.30.2