From 65f12a5022b2605b38d65d64092ee844843c5c3c Mon Sep 17 00:00:00 2001 From: jbjohnso Date: Thu, 21 Jun 2012 15:19:06 +0000 Subject: [PATCH] Wrap unlikely scenario in eval to hopefully keep DB worker up in the face of some nebulous problem git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@13139 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- perl-xCAT/xCAT/Table.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/perl-xCAT/xCAT/Table.pm b/perl-xCAT/xCAT/Table.pm index c9f81633e..ba51b3c35 100644 --- a/perl-xCAT/xCAT/Table.pm +++ b/perl-xCAT/xCAT/Table.pm @@ -216,9 +216,10 @@ sub init_dbworker { }; if ($@) { #this should never be reached, but leave it intact just in case my $err=$@; - xCAT::MsgUtils->message("S","xcatd: possible BUG encountered by xCAT DB worker ".$err); + eval { xCAT::MsgUtils->message("S","xcatd: possible BUG encountered by xCAT DB worker ".$err); }; } if ($intendedpid != $$) { #avoid redundant fork + eval { xCAT::MsgUtils->message("S","Pid $$ shutting itself down because only pid $intendedpid is permitted to be in this area"); }; exit(0); } }