[Affelio-cvs 511] CVS update: affelio/lib/Affelio/SNS

Back to archive index

Tadashi Okoshi slash****@users*****
2005年 7月 3日 (日) 20:42:51 JST


Index: affelio/lib/Affelio/SNS/Handshaker_s.pm
diff -u affelio/lib/Affelio/SNS/Handshaker_s.pm:1.19 affelio/lib/Affelio/SNS/Handshaker_s.pm:1.20
--- affelio/lib/Affelio/SNS/Handshaker_s.pm:1.19	Fri Jul  1 16:56:31 2005
+++ affelio/lib/Affelio/SNS/Handshaker_s.pm	Sun Jul  3 20:42:51 2005
@@ -14,7 +14,7 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 #
-# $Id: Handshaker_s.pm,v 1.19 2005/07/01 07:56:31 slash5234 Exp $
+# $Id: Handshaker_s.pm,v 1.20 2005/07/03 11:42:51 slash5234 Exp $
 
 use strict;
 use lib("../../../extlib/");
@@ -23,6 +23,7 @@
 use Crypt::RC5;
 use Crypt::DH;
 use MIME::Base64::Perl;
+use Error qw(:try);
 use lib("../../");
 use Affelio;
 use Affelio::SNS::FriendManager;
@@ -399,10 +400,15 @@
 					$timestamp,
 					$pass);
 	Affelio::misc::Debug::debug_print("server.HandShakeReply: add_friend finished.\n");
-	#Once we kill $af.
-	$af->{db}->commit;
-	$af->{db}->disconnect;
-	undef($af);
+
+	eval{
+	    $af->{db}->commit;
+	    $af->{db}->disconnect;
+	    undef($af);
+	};
+	if($@){
+	    Affelio::misc::Debug::debug_print($@);
+	}
 
         ###########################################
         #Get peer's friends list.
@@ -422,7 +428,6 @@
 	Affelio::misc::Debug::debug_print("server.HandshakeReply: save_F2List finished.");
 	#Make a new instance of Affelio
 
-
         ###########################################
         #Reply to client
         ###########################################


Affelio-cvs メーリングリストの案内
Back to archive index