[Rt-commit] [svn] r1863 - in rt/branches/PLATANO-EXPERIMENTAL-CSS: . lib/RT

jesse at pallas.eruditorum.org jesse at pallas.eruditorum.org
Thu Nov 11 03:51:03 EST 2004


Author: jesse
Date: Thu Nov 11 03:51:03 2004
New Revision: 1863

Modified:
   rt/branches/PLATANO-EXPERIMENTAL-CSS/   (props changed)
   rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Base.pm
Log:
 r9125 at tinbook:  jesse | 2004-11-11T04:07:50.357009Z
  r8941 at tinbook:  jesse | 2004-11-08T17:18:03.357715Z
  Added a bit of documentation to RT::Base; removed an unused line of code
  
 


Modified: rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Base.pm
==============================================================================
--- rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Base.pm	(original)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/RT/Base.pm	Thu Nov 11 03:51:03 2004
@@ -72,6 +72,9 @@
     if (@_) {
         $self->{'original_user'} = $self->{'user'};
         $self->{'user'} = shift;
+        # We need to weaken the CurrentUser ($self->{'user'}) reference
+        # if the object in question is the currentuser object.
+        # This avoids memory leaks.
         Scalar::Util::weaken($self->{'user'}) if (ref($self->{'user'}) &&
                                                     $self->{'user'} == $self );
     }
@@ -79,7 +82,6 @@
     unless ( ref( $self->{'user'}) ) {
         $RT::Logger->err( "$self was created without a CurrentUser\n" . Carp::cluck() );
         return (0);
-        die;
     }
     return ( $self->{'user'} );
 }


More information about the Rt-commit mailing list