diff --git a/MessageClient.cpp b/MessageClient.cpp index 4d5b4a506..80ceb04e6 100644 --- a/MessageClient.cpp +++ b/MessageClient.cpp @@ -378,13 +378,14 @@ void MessageClient::set_server_port (port_type server_port) m_->server_port_ = server_port; } -void MessageClient::send_raw_datagram (QByteArray const& message, QHostAddress const& dest_address +qint64 MessageClient::send_raw_datagram (QByteArray const& message, QHostAddress const& dest_address , port_type dest_port) { if (dest_port && !dest_address.isNull ()) { - m_->writeDatagram (message, dest_address, dest_port); + return m_->writeDatagram (message, dest_address, dest_port); } + return 0; } void MessageClient::add_blocked_destination (QHostAddress const& a) diff --git a/MessageClient.hpp b/MessageClient.hpp index be524fdb8..e1208f9c8 100644 --- a/MessageClient.hpp +++ b/MessageClient.hpp @@ -70,10 +70,10 @@ public: // of record marker Q_SLOT void logged_ADIF (QByteArray const& ADIF_record); - // this slot may be used to send arbitrary UDP datagrams to and + // this may be used to send arbitrary UDP datagrams to and // destination allowing the underlying socket to be used for general // UDP messaging if desired - Q_SLOT void send_raw_datagram (QByteArray const&, QHostAddress const& dest_address, port_type dest_port); + qint64 send_raw_datagram (QByteArray const&, QHostAddress const& dest_address, port_type dest_port); // disallowed message destination (does not block datagrams sent // with send_raw_datagram() above)