summaryrefslogtreecommitdiffstats
path: root/configdata.pm.in
diff options
context:
space:
mode:
authorAlexandr Nedvedicky <sashan@openssl.org>2024-11-26 09:05:09 +0100
committerTomas Mraz <tomas@openssl.org>2024-11-29 17:07:40 +0100
commit578760bb6aae6a9d7f3805eea66bab124d06c9b0 (patch)
tree03a293280cf942cce27d76ab5c76b85cfe57e8fb /configdata.pm.in
parentapps/passwd.c: Convert a redundant check to assert (diff)
downloadopenssl-578760bb6aae6a9d7f3805eea66bab124d06c9b0.tar.xz
openssl-578760bb6aae6a9d7f3805eea66bab124d06c9b0.zip
die() in .tmpl file should not be silently ignored.
call to die() in perl templates is currently ignored. any error printed by die() commad appears in template output. In order to make sure die() terminates processing we must ensure we emite `undef` value. This is ensured by adding a `BROKEN` callback to `fill_in()` Template method. The callback must return undef to stop processing. Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Tomas Mraz <tomas@openssl.org> (Merged from https://github.com/openssl/openssl/pull/26064)
Diffstat (limited to 'configdata.pm.in')
-rw-r--r--configdata.pm.in4
1 files changed, 2 insertions, 2 deletions
diff --git a/configdata.pm.in b/configdata.pm.in
index 68439ae93c..fea6004d6c 100644
--- a/configdata.pm.in
+++ b/configdata.pm.in
@@ -145,7 +145,7 @@ _____
# defined in one template stick around for the
# next, making them combinable
PACKAGE => 'OpenSSL::safe')
- or die $Text::Template::ERROR;
+ or die $OpenSSL::Template::ERROR;
close BUILDFILE;
rename("$buildfile.new", $buildfile)
or die "Trying to rename $buildfile.new to $buildfile: $!";
@@ -167,7 +167,7 @@ _____
# defined in one template stick around for the
# next, making them combinable
PACKAGE => 'OpenSSL::safe')
- or die $Text::Template::ERROR;
+ or die $OpenSSL::Template::ERROR;
close CONFIGURATION_H;
# When using stat() on Windows, we can get it to perform better by