remove unused getSocketReceiveBufferSize()

This commit is contained in:
Michael Davidsaver
2019-05-20 16:54:02 -07:00
parent d593462613
commit 3a2a3ac148
6 changed files with 0 additions and 54 deletions

View File

@ -494,25 +494,6 @@ bool BlockingUDPTransport::send(ByteBuffer* buffer, InetAddressType target) {
return allOK;
}
size_t BlockingUDPTransport::getSocketReceiveBufferSize() const {
// Get value of the SO_RCVBUF option for this DatagramSocket,
// that is the buffer size used by the platform for input on
// this DatagramSocket.
int sockBufSize = -1;
osiSocklen_t intLen = sizeof(int);
int retval = getsockopt(_channel, SOL_SOCKET, SO_RCVBUF, (char *)&sockBufSize, &intLen);
if(unlikely(retval<0))
{
char errStr[64];
epicsSocketConvertErrnoToString(errStr, sizeof(errStr));
LOG(logLevelError, "Socket getsockopt SO_RCVBUF error: %s.", errStr);
}
return (size_t)sockBufSize;
}
void BlockingUDPTransport::join(const osiSockAddr & mcastAddr, const osiSockAddr & nifAddr)
{

View File

@ -1289,27 +1289,6 @@ int BlockingTCPTransportCodec::write(
}
std::size_t BlockingTCPTransportCodec::getSocketReceiveBufferSize()
const {
osiSocklen_t intLen = sizeof(int);
int socketRecvBufferSize;
int retval = getsockopt(_channel, SOL_SOCKET, SO_RCVBUF,
(char *)&socketRecvBufferSize, &intLen);
if(retval<0) {
if (IS_LOGGABLE(logLevelDebug))
{
char strBuffer[64];
epicsSocketConvertErrnoToString(strBuffer, sizeof(strBuffer));
LOG(logLevelDebug, "Error getting SO_SNDBUF: %s", strBuffer);
}
}
return socketRecvBufferSize;
}
int BlockingTCPTransportCodec::read(epics::pvData::ByteBuffer* dst) {
std::size_t remaining;

View File

@ -83,8 +83,6 @@ public:
return _receiveBuffer.getSize();
}
virtual std::size_t getSocketReceiveBufferSize() const OVERRIDE FINAL;
virtual epics::pvData::int16 getPriority() const OVERRIDE FINAL {
return PVA_DEFAULT_PRIORITY;
}

View File

@ -335,7 +335,6 @@ public:
return &_socketAddress;
}
virtual void invalidDataStreamHandler() OVERRIDE FINAL;
virtual std::size_t getSocketReceiveBufferSize() const OVERRIDE FINAL;
virtual std::string getType() const OVERRIDE FINAL {
return std::string("tcp");

View File

@ -197,12 +197,6 @@ public:
*/
virtual std::size_t getReceiveBufferSize() const = 0;
/**
* Get socket receive buffer size.
* @return socket receive buffer size.
*/
virtual std::size_t getSocketReceiveBufferSize() const = 0;
/**
* Transport priority.
* @return protocol priority.

View File

@ -366,11 +366,6 @@ public:
return 0;
}
std::size_t getSocketReceiveBufferSize() const
{
return 16384;
}
void setRemoteTransportSocketReceiveBufferSize(
std::size_t socketReceiveBufferSize) {}