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:

@@ -821,7 +821,7 @@
# XXX skip references to scalars or other references.
# Otherwie 5.10 goes boom. may be 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;
    

Just another happy RT user (and embedder),

Ivan Kohler
CTO and Head Geek, Freeside Internet Services, Inc. http://freeside.biz/
Open-source billing, ticketing and provisioning
for ISPs, VoIP providers and online businesses

Thanks. Applied as df7a20d87c92774126ae7251c563214fc6eb82c0On Mon 8.Feb’10 at 19:47:04 -0800, Ivan Kohler wrote:

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:

@@ -821,7 +821,7 @@
# XXX skip references to scalars or other references.
# Otherwie 5.10 goes boom. may be 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;
    

Just another happy RT user (and embedder),


Ivan Kohler
CTO and Head Geek, Freeside Internet Services, Inc. http://freeside.biz/
Open-source billing, ticketing and provisioning
for ISPs, VoIP providers and online businesses


List info: http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-devel

signature.asc (197 Bytes)

Unless I’m mistaken, I believe this was included in 3.8.8 but is missing
in 3.9.6? Can it be applied to the 3.9 branch, too?

Ivan Kohler, President and Head Geek, Freeside Internet Services, Inc.
Open-source billing, ticketing and provisioning - http://www.freeside.biz/On Tue, Feb 09, 2010 at 07:35:53AM -0800, Jesse Vincent wrote:

Thanks. Applied as df7a20d87c92774126ae7251c563214fc6eb82c0

On Mon 8.Feb’10 at 19:47:04 -0800, Ivan Kohler wrote:

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:

@@ -821,7 +821,7 @@
# XXX skip references to scalars or other references.
# Otherwie 5.10 goes boom. may be 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;
    

Just another happy RT user (and embedder),


Ivan Kohler
CTO and Head Geek, Freeside Internet Services, Inc. http://freeside.biz/
Open-source billing, ticketing and provisioning
for ISPs, VoIP providers and online businesses


List info: http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-devel

Unless I’m mistaken, I believe this was included in 3.8.8 but is missing
in 3.9.6? Can it be applied to the 3.9 branch, too?

We periodically merge forward from 3.8 to 3.9. It’ll happen again before the 4.0 release, though I don’t know when it’s next planned.

(commit df7a20d87c92774126ae7251c563214fc6eb82c0)On Wed, Nov 17, 2010 at 09:06:29PM -0500, Jesse Vincent wrote:

On Wed, Nov 17, 2010 at 06:01:33PM -0800, Ivan Kohler wrote:

Unless I’m mistaken, I believe this was included in 3.8.8 but is missing
in 3.9.6? Can it be applied to the 3.9 branch, too?

We periodically merge forward from 3.8 to 3.9. It’ll happen again
before the 4.0 release, though I don’t know when it’s next planned.

Sorry to be a pest, but I was checking on this again, and found that I
was mistaken, it was not included in 3.8.8 and in fact was reverted a
few days after being commited, by ruz in
d27eef5a57b2d6abba96da6f93d6cbddd4e8d24b

The commit message doesn’t say anything about it (and reverts the
incidental spelling fixes), so perhaps it was a mistake?

Would it be possible for this patch to be reapplied?

Ivan Kohler, President and Head Geek, Freeside Internet Services, Inc.
Open-source billing, ticketing and provisioning - http://www.freeside.biz/

Sure. Thank you for spotting and reporting.

[3.8-trunk 404c473] return back accidentally reverted changeOn Wed, Jan 12, 2011 at 8:17 AM, Ivan Kohler ivan-rt-devel@420.am wrote:

(commit df7a20d87c92774126ae7251c563214fc6eb82c0)

On Wed, Nov 17, 2010 at 09:06:29PM -0500, Jesse Vincent wrote:

On Wed, Nov 17, 2010 at 06:01:33PM -0800, Ivan Kohler wrote:

Unless I’m mistaken, I believe this was included in 3.8.8 but is missing
in 3.9.6? Can it be applied to the 3.9 branch, too?

We periodically merge forward from 3.8 to 3.9. It’ll happen again
before the 4.0 release, though I don’t know when it’s next planned.

Sorry to be a pest, but I was checking on this again, and found that I
was mistaken, it was not included in 3.8.8 and in fact was reverted a
few days after being commited, by ruz in
d27eef5a57b2d6abba96da6f93d6cbddd4e8d24b

The commit message doesn’t say anything about it (and reverts the
incidental spelling fixes), so perhaps it was a mistake?

Would it be possible for this patch to be reapplied?


Ivan Kohler, President and Head Geek, Freeside Internet Services, Inc.
Open-source billing, ticketing and provisioning - http://www.freeside.biz/


List info: http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-devel

Best regards, Ruslan.

Sure. Thank you for spotting and reporting.

[3.8-trunk 404c473] return back accidentally reverted change

Really sorry to continue being such a pest here, but can I ask that this
be applied to the 4.0 branch before the 4.0 release?

(Perhaps since it got reverted and re-commited it missed the normal
periodic merge-forward from 3.8 to 4.0?)

Thanks!

Ivan Kohler, President and Head Geek, Freeside Internet Services, Inc.
Open-source billing, ticketing and provisioning - http://www.freeside.biz/> On Wed, Jan 12, 2011 at 8:17 AM, Ivan Kohler ivan-rt-devel@420.am wrote:

(commit df7a20d87c92774126ae7251c563214fc6eb82c0)

On Wed, Nov 17, 2010 at 09:06:29PM -0500, Jesse Vincent wrote:

On Wed, Nov 17, 2010 at 06:01:33PM -0800, Ivan Kohler wrote:

Unless I’m mistaken, I believe this was included in 3.8.8 but is missing
in 3.9.6? �Can it be applied to the 3.9 branch, too?

We periodically merge forward from 3.8 to 3.9. �It’ll happen again
before the 4.0 release, though I don’t know when it’s next planned.

Sorry to be a pest, but I was checking on this again, and found that I
was mistaken, it was not included in 3.8.8 and in fact was reverted a
few days after being commited, by ruz in
d27eef5a57b2d6abba96da6f93d6cbddd4e8d24b

The commit message doesn’t say anything about it (and reverts the
incidental spelling fixes), so perhaps it was a mistake?

Would it be possible for this patch to be reapplied?

Sure. Thank you for spotting and reporting.

[3.8-trunk 404c473] return back accidentally reverted change

Really sorry to continue being such a pest here, but can I ask that this
be applied to the 4.0 branch before the 4.0 release?

This will not happen for 4.0.0

(Perhaps since it got reverted and re-commited it missed the normal
periodic merge-forward from 3.8 to 4.0?)

Please provide a patch to rt-bugs against 4.0-trunk so it can be
linked to a release.

-kevin> > On Wed, Jan 12, 2011 at 8:17 AM, Ivan Kohler ivan-rt-devel@420.am wrote:

(commit df7a20d87c92774126ae7251c563214fc6eb82c0)

On Wed, Nov 17, 2010 at 09:06:29PM -0500, Jesse Vincent wrote:

On Wed, Nov 17, 2010 at 06:01:33PM -0800, Ivan Kohler wrote:

Unless I’m mistaken, I believe this was included in 3.8.8 but is missing
in 3.9.6? Can it be applied to the 3.9 branch, too?

We periodically merge forward from 3.8 to 3.9. It’ll happen again
before the 4.0 release, though I don’t know when it’s next planned.

Sorry to be a pest, but I was checking on this again, and found that I
was mistaken, it was not included in 3.8.8 and in fact was reverted a
few days after being commited, by ruz in
d27eef5a57b2d6abba96da6f93d6cbddd4e8d24b

The commit message doesn’t say anything about it (and reverts the
incidental spelling fixes), so perhaps it was a mistake?

Would it be possible for this patch to be reapplied?


List info: http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-devel

Really sorry to continue being such a pest here, but can I ask that this
be applied to the 4.0 branch before the 4.0 release?

This will not happen for 4.0.0

It is, however, in 4.0-trunk, meaning that it will be in 4.0.1, which we
expect to follow 4.0.0 in a reasonable timeframe.

(Perhaps since it got reverted and re-commited it missed the normal
periodic merge-forward from 3.8 to 4.0?)

No, the 4.0.0 release process was simply already in progress when the
merge-forward after 3.8.9 happened. Specifically:

2011-01-12 - Your patch lands on 3.8-trunk
2011-02-14 - 4.0.0-releng branched
2011-02-15 - RT 3.8.9 released, containing your fix
2011-03-03 - 3.8-trunk merged to 4.0-trunk

  • Alex