From df14b3c812526fe110dd4ea63b12281de9d1531b Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Tue, 24 Oct 2017 16:22:26 -0700 Subject: [PATCH] handle failure to connect to zmc in zms gracefully --- src/zm_stream.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/zm_stream.cpp b/src/zm_stream.cpp index 8ae9f5549..8002c4f18 100644 --- a/src/zm_stream.cpp +++ b/src/zm_stream.cpp @@ -44,7 +44,11 @@ bool StreamBase::loadMonitor( int monitor_id ) { Fatal( "Unable to load monitor id %d for streaming", monitor_id ); return( false ); } - monitor->connect(); + if ( ! monitor->connect() ) { + Fatal( "Unable to connect to monitor id %d for streaming", monitor_id ); + return( false ); + } + return( true ); }