[Rt-commit] rt branch, 4.4/upgrade-acl-abs-path, created. rt-4.4.4-131-g3d02acd65c

? sunnavy sunnavy at bestpractical.com
Thu Aug 13 16:29:31 EDT 2020


The branch, 4.4/upgrade-acl-abs-path has been created
        at  3d02acd65c28d983b082cf940b6f3c9aec3f12f8 (commit)

- Log -----------------------------------------------------------------
commit 3d02acd65c28d983b082cf940b6f3c9aec3f12f8
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Fri Aug 14 03:52:19 2020 +0800

    Find full path for processing acl files on upgrade
    
    Starting with perl 5.26, . (the current directory) is no
    longer in @INC by default, which causes upgrade steps that insert
    acl to fail when RT::Handle tries to require the file.
    Set the full path so the acl file can be found.
    
    This is to mirror changes in 8c61476b50, which is to fix indexes.

diff --git a/lib/RT/Handle.pm b/lib/RT/Handle.pm
index 29e929e7b7..43dd36762e 100644
--- a/lib/RT/Handle.pm
+++ b/lib/RT/Handle.pm
@@ -468,6 +468,9 @@ sub InsertACL {
         $path = $base_path;
     }
 
+    # Get the full path since . is no longer in @INC after perl 5.24
+    $path = Cwd::abs_path($path);
+
     local *acl;
     do $path || return (0, "Couldn't load ACLs: " . $@);
     my @acl = acl($dbh);

-----------------------------------------------------------------------


More information about the rt-commit mailing list