[pve-devel] r5651 - in pve-cluster/trunk/data: . perl

svn-commits at proxmox.com svn-commits at proxmox.com
Mon Mar 7 14:46:43 CET 2011


Author: dietmar
Date: 2011-03-07 14:46:43 +0100 (Mon, 07 Mar 2011)
New Revision: 5651

Modified:
   pve-cluster/trunk/data/ChangeLog
   pve-cluster/trunk/data/perl/Cluster.pm
Log:
 allow to return 'undef'


Modified: pve-cluster/trunk/data/ChangeLog
===================================================================
--- pve-cluster/trunk/data/ChangeLog	2011-03-07 13:30:56 UTC (rev 5650)
+++ pve-cluster/trunk/data/ChangeLog	2011-03-07 13:46:43 UTC (rev 5651)
@@ -1,5 +1,7 @@
 2011-03-07  Proxmox Support Team  <support at proxmox.com>
 
+	* perl/Cluster.pm (ipcc_send_rec*): allow to return 'undef'
+
 	* src/status.c (cfs_rrd_dump): impl. rrd dump
 
 	* perl/Cluster.pm (broadcast_rrd): start rrd integration

Modified: pve-cluster/trunk/data/perl/Cluster.pm
===================================================================
--- pve-cluster/trunk/data/perl/Cluster.pm	2011-03-07 13:30:56 UTC (rev 5650)
+++ pve-cluster/trunk/data/perl/Cluster.pm	2011-03-07 13:46:43 UTC (rev 5651)
@@ -234,7 +234,7 @@
 
     my $res = PVE::IPCC::ipcc_send_rec($msgid, $data);
 
-    die "ipcc_send_rec failed: $!\n" if !defined($res);
+    die "ipcc_send_rec failed: $!\n" if !defined($res) && ($! = 0);
 
     return $res;
 };
@@ -244,7 +244,7 @@
 
     my $res = PVE::IPCC::ipcc_send_rec($msgid, $data);
 
-    die "ipcc_send_rec failed: $!\n" if !defined($res);
+    die "ipcc_send_rec failed: $!\n" if !defined($res) && ($! = 0);
 
     return decode_json($res);
 };




More information about the pve-devel mailing list