snprintf(buffer, bufsize, "%d", sock->my_port);
FORWARD;
- if (this->tls) {
- ADDSTRING(" (TLS)");
- FORWARD;
- }
-
if (this->server) {
ADDSTRING(", virtual-server=");
ADDSTRING(this->server);
snprintf(buffer, bufsize, "%d", sock->my_port);
FORWARD;
+ if (this->tls) {
+ ADDSTRING(" (TLS)");
+ FORWARD;
+ }
+
if (this->server) {
ADDSTRING(" as server ");
ADDSTRING(this->server);
{
rad_listen_t *this;
listen_socket_t *sock;
+#ifndef NDEBUG
+ char buffer[256];
+#endif
if (!home) return 0;
sock->my_port = src_port;
sock->proto = home->proto;
+ if (debug_flag >= 2) {
+ this->print(this, buffer, sizeof(buffer));
+ DEBUG("Opening new %s", buffer);
+ }
+
#ifdef WITH_TCP
- sock->last_packet = time(NULL);
+ sock->opened = sock->last_packet = time(NULL);
if (home->proto == IPPROTO_TCP) {
this->recv = proxy_socket_tcp_recv;
this->fd = fr_socket(&home->src_ipaddr, src_port);
if (this->fd < 0) {
- DEBUG("Failed opening client socket: %s", fr_strerror());
+ this->print(this, buffer,sizeof(buffer));
+ DEBUG("Failed opening client socket ::%s:: : %s",
+ buffer, fr_strerror());
listen_free(&this);
return 0;
}