Browse Source

Ticket 48826 - 52updateAESplugin.pl may fail on older versions of perl

Bug Description:  The warning class for warnings 'experimental::smartmatch';
does not exist on EL7

Fix Description:  Check the perl version before attempting the warning.

https://fedorahosted.org/389/ticket/48826

Author: wibrown

Review by: mreynolds (Thanks!)
William Brown 9 years ago
parent
commit
d18fa55954
1 changed files with 2 additions and 1 deletions
  1. 2 1
      ldap/admin/src/scripts/52updateAESplugin.pl

+ 2 - 1
ldap/admin/src/scripts/52updateAESplugin.pl

@@ -6,7 +6,8 @@ use File::Basename;
 use File::Copy;
 use DSUtil qw(debug serverIsRunning);
 
-no warnings 'experimental::smartmatch';
+# no warnings 'experimental::smartmatch';
+no if $] >= 5.017011, warnings => 'experimental::smartmatch';
 
 #
 # Check if there is a DES plugin and make sure the AES plugin contains the same attributes