#include "repeaterClient.h"
Definition at line 40 of file repeaterClient.h.
repeaterClient::repeaterClient |
( |
const osiSockAddr & |
from | ) |
|
Definition at line 127 of file repeater.cpp.
131 unsigned port = ntohs ( from.
ia.sin_port );
epicsPlacementDeleteOperator((void *, tsFreeList< repeaterClient, 0x20 > &)) private SOCKE sock)
unsigned short port() const
#define debugPrintf(argsInParen)
repeaterClient::~repeaterClient |
( |
| ) |
|
Definition at line 218 of file repeater.cpp.
LIBCOM_API void epicsStdCall epicsSocketDestroy(SOCKET s)
unsigned short epicsUInt16
epicsPlacementDeleteOperator((void *, tsFreeList< repeaterClient, 0x20 > &)) private SOCKE sock)
unsigned short port() const
#define debugPrintf(argsInParen)
bool repeaterClient::connect |
( |
| ) |
|
Definition at line 136 of file repeater.cpp.
140 if (
int sockerrno = makeSocket ( PORT_ANY,
false, & this->
sock ) ) {
143 sockErrBuf,
sizeof ( sockErrBuf ), sockerrno );
144 fprintf (
stderr,
"%s: no client sock because \"%s\"\n",
145 __FILE__, sockErrBuf );
149 status =
::connect ( this->
sock, &this->from.sa, sizeof ( this->from.sa ) );
153 sockErrBuf,
sizeof ( sockErrBuf ) );
154 fprintf (
stderr,
"%s: unable to connect client sock because \"%s\"\n",
155 __FILE__, sockErrBuf );
epicsPlacementDeleteOperator((void *, tsFreeList< repeaterClient, 0x20 > &)) private SOCKE sock)
void epicsSocketConvertErrnoToString(char *pBuf, unsigned bufSize)
void epicsSocketConvertErrorToString(char *pBuf, unsigned bufSize, int theSockError)
bool repeaterClient::identicalAddress |
( |
const osiSockAddr & |
from | ) |
|
|
inline |
Definition at line 259 of file repeater.cpp.
261 if ( fromIn.sa.sa_family == this->from.sa.sa_family ) {
262 if ( fromIn.ia.sin_port == this->from.ia.sin_port) {
263 if ( fromIn.ia.sin_addr.s_addr == this->from.ia.sin_addr.s_addr ) {
bool repeaterClient::identicalPort |
( |
const osiSockAddr & |
from | ) |
|
|
inline |
Definition at line 271 of file repeater.cpp.
273 if ( fromIn.sa.sa_family == this->from.sa.sa_family ) {
274 if ( fromIn.ia.sin_port == this->from.ia.sin_port) {
void repeaterClient::operator delete |
( |
void * |
| ) |
|
Definition at line 229 of file repeater.cpp.
236 errlogPrintf (
"%s:%d this compiler is confused about placement delete - memory was probably leaked",
237 __FILE__, __LINE__ );
int errlogPrintf(const char *pFormat,...)
unsigned short repeaterClient::port |
( |
| ) |
const |
|
inline |
Definition at line 254 of file repeater.cpp.
256 return ntohs ( this->from.ia.sin_port );
bool repeaterClient::sendConfirm |
( |
| ) |
|
Definition at line 162 of file repeater.cpp.
167 memset ( (
char *) &confirm,
'\0',
sizeof (confirm) );
169 confirm.
m_available = this->from.ia.sin_addr.s_addr;
170 status = send ( this->
sock, (
char *) &confirm,
171 sizeof (confirm), 0 );
173 assert ( status ==
sizeof ( confirm ) );
182 sockErrBuf,
sizeof ( sockErrBuf ) );
183 debugPrintf ( (
"CA Repeater: confirm req err was \"%s\"\n", sockErrBuf) );
#define SOCK_ECONNREFUSED
#define assert(exp)
Declare that a condition should be true.
epicsPlacementDeleteOperator((void *, tsFreeList< repeaterClient, 0x20 > &)) private SOCKE sock)
void epicsSocketConvertErrnoToString(char *pBuf, unsigned bufSize)
#define debugPrintf(argsInParen)
bool repeaterClient::sendMessage |
( |
const void * |
pBuf, |
|
|
unsigned |
bufSize |
|
) |
| |
Definition at line 188 of file repeater.cpp.
192 status = send ( this->
sock, (
char *) pBuf, bufSize, 0 );
194 assert ( static_cast <unsigned> ( status ) == bufSize );
205 epicsUInt16 port = ntohs ( this->from.ia.sin_port );
206 debugPrintf ( (
"Client refused message %u\n", port ) );
212 debugPrintf ( (
"CA Repeater: UDP send err was \"%s\"\n", sockErrBuf) );
#define SOCK_ECONNREFUSED
#define assert(exp)
Declare that a condition should be true.
unsigned short epicsUInt16
epicsPlacementDeleteOperator((void *, tsFreeList< repeaterClient, 0x20 > &)) private SOCKE sock)
unsigned short port() const
void epicsSocketConvertErrnoToString(char *pBuf, unsigned bufSize)
#define debugPrintf(argsInParen)
bool repeaterClient::verify |
( |
| ) |
|
Definition at line 281 of file repeater.cpp.
284 int sockerrno = makeSocket ( this->
port (),
false, & tmpSock );
291 if ( sockerrno == 0 ) {
298 sockErrBuf,
sizeof ( sockErrBuf ), sockerrno );
299 fprintf (
stderr,
"CA Repeater: Bind test error \"%s\"\n",
LIBCOM_API void epicsStdCall epicsSocketDestroy(SOCKET s)
unsigned short port() const
void epicsSocketConvertErrorToString(char *pBuf, unsigned bufSize, int theSockError)
The documentation for this class was generated from the following files: