[LON-CAPA-cvs] cvs: loncom /publisher lonpublisher.pm

raeburn raeburn@source.lon-capa.org
Thu, 19 Nov 2009 05:18:08 -0000


raeburn		Thu Nov 19 05:18:08 2009 EDT

  Modified files:              
    /loncom/publisher	lonpublisher.pm 
  Log:
  - Bug 6122.
    - &notify (includes session lock clean-up) needs to be at start of chain of PerlCleanupHandlers so $env{'user.environment is still defined during clean-up.
  
  
Index: loncom/publisher/lonpublisher.pm
diff -u loncom/publisher/lonpublisher.pm:1.262 loncom/publisher/lonpublisher.pm:1.263
--- loncom/publisher/lonpublisher.pm:1.262	Thu Jul 30 09:42:25 2009
+++ loncom/publisher/lonpublisher.pm	Thu Nov 19 05:18:08 2009
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Publication Handler
 #
-# $Id: lonpublisher.pm,v 1.262 2009/07/30 09:42:25 bisitz Exp $
+# $Id: lonpublisher.pm,v 1.263 2009/11/19 05:18:08 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1747,7 +1747,8 @@
 # ------------------------------------------------------------- Trigger updates
     push(@{$modified_urls},[$target,$source]);
     unless ($registered_cleanup) {
-	$r->register_cleanup(\&notify);
+        my $handlers = $r->get_handlers('PerlCleanupHandler');
+        $r->set_handlers('PerlCleanupHandler' => [\&notify,@{$handlers}]);
 	$registered_cleanup=1;
     }