mirror of
https://github.com/zeromq/libzmq.git
synced 2025-10-27 11:06:52 +01:00
Remove of ZMQ_IDENTITY_FD socket option
Revert "linking fd to pipe identity via socket option"
This reverts commit fe3e8c5c70.
Conflicts:
include/zmq.h
src/pipe.hpp
src/session_base.cpp
This commit is contained in:
@@ -133,33 +133,6 @@ int zmq::router_t::xsetsockopt (int option_, const void *optval_,
|
||||
return -1;
|
||||
}
|
||||
|
||||
int zmq::router_t::xgetsockopt (int option_, const void *optval_,
|
||||
size_t *optvallen_)
|
||||
{
|
||||
switch (option_) {
|
||||
case ZMQ_IDENTITY_FD:
|
||||
if (optval_==NULL && optvallen_) {
|
||||
*optvallen_=sizeof(fd_t);
|
||||
return 0;
|
||||
}
|
||||
if (optval_ && optvallen_ && *optvallen_) {
|
||||
blob_t identity= blob_t((unsigned char*)optval_,*optvallen_);
|
||||
outpipes_t::iterator it = outpipes.find (identity);
|
||||
if (it == outpipes.end() ){
|
||||
return ENOTSOCK;
|
||||
}
|
||||
*((fd_t*)optval_)=it->second.pipe->assoc_fd;
|
||||
*optvallen_=sizeof(fd_t);
|
||||
return 0;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
errno = EINVAL;
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
||||
void zmq::router_t::xpipe_terminated (pipe_t *pipe_)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user