]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/MgrClient: skip sending stats if no session
authorSage Weil <sage@redhat.com>
Fri, 9 Jun 2017 16:15:18 +0000 (12:15 -0400)
committerSage Weil <sage@redhat.com>
Thu, 15 Jun 2017 17:41:30 +0000 (13:41 -0400)
Signed-off-by: Sage Weil <sage@redhat.com>
src/mgr/MgrClient.cc

index 282bd4f37ecb0b5094f25279bcf28d58cb7137ef..c7774959d22e0c3fd5ffef0ac205988bc08ec46a 100644 (file)
@@ -264,7 +264,7 @@ void MgrClient::send_report()
 
 void MgrClient::send_pgstats()
 {
-  if (pgstats_cb) {
+  if (pgstats_cb && session) {
     session->con->send_message(pgstats_cb());
   }
 }