mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-13 16:46:47 +00:00
shmem: fail earlier if given an unsupported socket type
This commit is contained in:
parent
cf004f69b2
commit
d03a504ccd
|
@ -58,6 +58,12 @@ class Socket final : public fair::mq::Socket
|
||||||
, fTimeout(100)
|
, fTimeout(100)
|
||||||
{
|
{
|
||||||
assert(context);
|
assert(context);
|
||||||
|
|
||||||
|
if (type == "sub" || type == "pub") {
|
||||||
|
LOG(error) << "PUB/SUB socket type is not supported for shared memory transport";
|
||||||
|
throw SocketError("PUB/SUB socket type is not supported for shared memory transport");
|
||||||
|
}
|
||||||
|
|
||||||
fSocket = zmq_socket(context, GetConstant(type));
|
fSocket = zmq_socket(context, GetConstant(type));
|
||||||
|
|
||||||
if (fSocket == nullptr) {
|
if (fSocket == nullptr) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user