[MOBY-guts] biomoby commit
Eddie Kawas
kawas at dev.open-bio.org
Wed Apr 16 13:52:03 UTC 2008
kawas
Wed Apr 16 09:52:03 EDT 2008
Update of /home/repository/moby/moby-live/Perl/MOBY-Server/share/cgi
In directory dev.open-bio.org:/tmp/cvs-serv2069/Perl/MOBY-Server/share/cgi
Modified Files:
service_tester.pl
Log Message:
*modified how IPC::Shareable is used to prevent shared memory from being recycled properly
moby-live/Perl/MOBY-Server/share/cgi service_tester.pl,1.1,1.2
===================================================================
RCS file: /home/repository/moby/moby-live/Perl/MOBY-Server/share/cgi/service_tester.pl,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- /home/repository/moby/moby-live/Perl/MOBY-Server/share/cgi/service_tester.pl 2008/02/21 00:21:27 1.1
+++ /home/repository/moby/moby-live/Perl/MOBY-Server/share/cgi/service_tester.pl 2008/04/16 13:52:03 1.2
@@ -68,7 +68,7 @@
close OUT;
# create some shared variables
-my $alive_handle = tie %ALIVE, 'IPC::Shareable', undef, { destroy => 'yes' };
+my $alive_handle = tie %ALIVE, 'IPC::Shareable', undef, { } or die "\n\tCouldn't tie shared variable:\n$!";
# create the central client and get all service providers once
my $central =
@@ -188,7 +188,14 @@
$root->appendChild($element);
}
-IPC::Shareable->clean_up_all;
+# clean up the shared memory
+eval {
+ warn "Attempting to clean up shared memory ...";
+ IPC::Shareable->clean_up_all;
+ warn "Shared memory cleaned up successfully";
+};
+
+warn "There was a problem cleaning up shared memory segments:\n$@\n" if $@;
open( OUT, ">$DIRECTORY/$FILENAME" ) || die("Cannot Open File $DIRECTORY/$FILENAME $!");
print OUT $doc->toString(1);
More information about the MOBY-guts
mailing list