Fail gracefully if network rig connection not established

This commit is contained in:
Bill Somerville 2021-10-28 11:29:35 +01:00
parent 9d31ec843e
commit c0a5bad58a
No known key found for this signature in database
GPG Key ID: D864B06D1E81618F
2 changed files with 3 additions and 3 deletions

View File

@ -385,7 +385,7 @@ auto DXLabSuiteCommanderTransceiver::get_mode () -> MODE
void DXLabSuiteCommanderTransceiver::simple_command (QString const& cmd)
{
Q_ASSERT (commander_);
if (!commander_) return;
CAT_TRACE (cmd);
@ -398,7 +398,7 @@ void DXLabSuiteCommanderTransceiver::simple_command (QString const& cmd)
QString DXLabSuiteCommanderTransceiver::command_with_reply (QString const& cmd)
{
Q_ASSERT (commander_);
if (!commander_) return QString {};
if (!write_to_port (cmd))
{

View File

@ -1005,7 +1005,7 @@ void HRDTransceiver::do_poll ()
QString HRDTransceiver::send_command (QString const& cmd, bool prepend_context, bool recurse)
{
Q_ASSERT (hrd_);
if (!hrd_) return QString {};
QString result;