mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2025-02-20 17:52:46 +00:00
Minor debug output changes
This commit is contained in:
parent
876aa0883d
commit
1bc33ae8d7
@ -71,7 +71,7 @@
|
||||
/* these are originally defined in tcp_impl.h */
|
||||
#ifndef TCP_TMR_INTERVAL
|
||||
/* The TCP timer interval in milliseconds. */
|
||||
#define TCP_TMR_INTERVAL 250
|
||||
#define TCP_TMR_INTERVAL 20
|
||||
#endif /* TCP_TMR_INTERVAL */
|
||||
|
||||
#ifndef TCP_FAST_INTERVAL
|
||||
@ -113,7 +113,7 @@
|
||||
------------------------------------------------------------------------------*/
|
||||
|
||||
|
||||
#define LWIP_CHKSUM_ALGORITHM 2
|
||||
#define LWIP_CHKSUM_ALGORITHM 0
|
||||
|
||||
|
||||
/**
|
||||
@ -146,7 +146,7 @@
|
||||
* MEMP_NUM_RAW_PCB: Number of raw connection PCBs
|
||||
* (requires the LWIP_RAW option)
|
||||
*/
|
||||
#define MEMP_NUM_RAW_PCB 32
|
||||
#define MEMP_NUM_RAW_PCB 128
|
||||
|
||||
/**
|
||||
* MEMP_NUM_UDP_PCB: the number of UDP protocol control blocks. One
|
||||
|
@ -308,7 +308,6 @@ void NetconEthernetTap::closeAll()
|
||||
}
|
||||
|
||||
#define ZT_LWIP_TCP_TIMER_INTERVAL 5
|
||||
//#define ZT_LWIP_ARP_TIMER_INTERVAL 5000
|
||||
|
||||
void NetconEthernetTap::threadMain()
|
||||
throw()
|
||||
@ -328,13 +327,9 @@ void NetconEthernetTap::threadMain()
|
||||
fprintf(stderr, "- IP_REASSEMBLY = %d\n", IP_REASSEMBLY);
|
||||
fprintf(stderr, "- TCP_WND = %d\n", TCP_WND);
|
||||
fprintf(stderr, "- TCP_MSS = %d\n", TCP_MSS);
|
||||
fprintf(stderr, "- NO_SYS = %d\n", NO_SYS);
|
||||
fprintf(stderr, "- LWIP_SOCKET = %d\n", LWIP_SOCKET);
|
||||
fprintf(stderr, "- LWIP_NETCONN = %d\n", LWIP_NETCONN);
|
||||
fprintf(stderr, "- ARP_TMR_INTERVAL = %d\n", ARP_TMR_INTERVAL);
|
||||
fprintf(stderr, "- TCP_TMR_INTERVAL = %d\n", TCP_TMR_INTERVAL);
|
||||
fprintf(stderr, "- IP_TMR_INTERVAL = %d\n", IP_TMR_INTERVAL);
|
||||
fprintf(stderr, "- DEFAULT_READ_BUFFER_SIZE = %d\n", DEFAULT_READ_BUFFER_SIZE);
|
||||
|
||||
// Main timer loop
|
||||
while (_run) {
|
||||
@ -670,7 +665,6 @@ err_t NetconEthernetTap::nc_recved(void *arg, struct tcp_pcb *tpcb, struct pbuf
|
||||
fprintf(stderr, "nc_recved(): unable to write entire pbuf to buffer\n");
|
||||
}
|
||||
l->tap->lwipstack->_tcp_recved(tpcb, n); // TODO: would it be more efficient to call this once at the end?
|
||||
fprintf(stderr, "nc_recved(): streamSend(%d bytes)\n", n);
|
||||
}
|
||||
else {
|
||||
fprintf(stderr, "nc_recved(): No data written to intercept buffer\n");
|
||||
@ -830,8 +824,8 @@ void NetconEthernetTap::handle_retval(PhySocket *sock, void **uptr, unsigned cha
|
||||
TcpConnection *conn = (TcpConnection*)*uptr;
|
||||
if(conn->pending) {
|
||||
memcpy(&(conn->perceived_fd), &buf[1], sizeof(int));
|
||||
fprintf(stderr, "handle_retval(): Mapping [our=%d -> their=%d]\n",
|
||||
_phy.getDescriptor(conn->dataSock), conn->perceived_fd);
|
||||
//fprintf(stderr, "handle_retval(): Mapping [our=%d -> their=%d]\n",
|
||||
//_phy.getDescriptor(conn->dataSock), conn->perceived_fd);
|
||||
conn->pending = false;
|
||||
}
|
||||
}
|
||||
@ -862,7 +856,7 @@ void NetconEthernetTap::handle_socket(PhySocket *sock, void **uptr, struct socke
|
||||
new_conn->their_fd = fds[1];
|
||||
tcp_connections.push_back(new_conn);
|
||||
sock_fd_write(_phy.getDescriptor(sock), fds[1]);
|
||||
fprintf(stderr, "handle_socket(): socketpair = { our=%d, their=%d}\n", fds[0], fds[1]);
|
||||
//fprintf(stderr, "handle_socket(): socketpair = { our=%d, their=%d}\n", fds[0], fds[1]);
|
||||
/* Once the client tells us what its fd is for the other end,
|
||||
we can then complete the mapping */
|
||||
new_conn->pending = true;
|
||||
|
@ -185,7 +185,7 @@ static err_t low_level_output(struct netif *netif, struct pbuf *p)
|
||||
{
|
||||
//fprintf(stderr, "low_level_output()\n");
|
||||
struct pbuf *q;
|
||||
char buf[ZT1_MAX_MTU+32];
|
||||
char buf[ZT_MAX_MTU+32];
|
||||
char *bufptr;
|
||||
int tot_len = 0;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user