[Rt-commit] rt branch, 3.8-trunk, updated. rt-3.8.7-148-gdf7a20d

jesse jesse at bestpractical.com
Tue Feb 9 10:28:09 EST 2010


The branch, 3.8-trunk has been updated
       via  df7a20d87c92774126ae7251c563214fc6eb82c0 (commit)
      from  4ec85e646f688744bd42fc9d83e6e43fef91870e (commit)

Summary of changes:
 lib/RT/Config.pm |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

- Log -----------------------------------------------------------------
commit df7a20d87c92774126ae7251c563214fc6eb82c0
Author: Jesse Vincent <jesse at bestpractical.com>
Date:   Tue Feb 9 07:26:41 2010 -0800

    RT::Config fix for proper loading when Fcntl is loaded.
    
    Date: Mon, 8 Feb 2010 19:47:04 -0800
    From: Ivan Kohler <ivan-rt-devel at 420.am>
    To: rt-devel at lists.bestpractical.com
    Cc: rt at northpb.com
    Subject: [Rt-devel] [patch] RT 3.8 bug when using Fcntl perl module
    
    Hi,
    
    I find myself having recently encountered the bug indicated here:
    
    http://lists.fsck.com/pipermail/rt-users/2009-September/061167.html
    
    (including "use Fcntl;" in a script which uses the RT libraries
    and attempts to LoadConfig() and Init() causes io error out with an
    error: "Couldn't load RT config file RT_SiteConfig.pm: Not a SCALAR
    reference")
    
    The following patch to lib/RT/Config.pm should fix the problem and allow
    use of RT libraries while Fcntl (and probably other similar modules
    which export symbols) are loaded concurrently:

diff --git a/lib/RT/Config.pm b/lib/RT/Config.pm
index 6fc1b89..2604a24 100644
--- a/lib/RT/Config.pm
+++ b/lib/RT/Config.pm
@@ -829,9 +829,9 @@ sub SetFromConfig {
 
             # get entry for type we are looking for
             # XXX skip references to scalars or other references.
-            # Otherwie 5.10 goes boom. may be we should skip any
+            # Otherwise 5.10 goes boom. maybe we should skip any
             # reference
-            return if ref($entry) eq 'SCALAR' || ref($entry) eq 'REF';
+            next if ref($entry) eq 'SCALAR' || ref($entry) eq 'REF';
             my $entry_ref = *{$entry}{ ref($ref) };
             next unless $entry_ref;
 

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


More information about the Rt-commit mailing list