Make tcp_debug_state_str() always available, not only in DEBUG mode

This commit is contained in:
goldsimon 2009-10-07 17:44:59 +00:00
parent bd2bc2ee14
commit 68f92050e9
2 changed files with 7 additions and 7 deletions

View File

@ -1302,6 +1302,12 @@ tcp_eff_send_mss(u16_t sendmss, struct ip_addr *addr)
}
#endif /* TCP_CALCULATE_EFF_SEND_MSS */
const char*
tcp_debug_state_str(enum tcp_state s)
{
return tcp_state_str[s];
}
#if TCP_DEBUG || TCP_INPUT_DEBUG || TCP_OUTPUT_DEBUG
/**
* Print a tcp header for debugging purposes.
@ -1339,12 +1345,6 @@ tcp_debug_print(struct tcp_hdr *tcphdr)
LWIP_DEBUGF(TCP_DEBUG, ("+-------------------------------+\n"));
}
const char*
tcp_debug_state_str(enum tcp_state s)
{
return tcp_state_str[s];
}
/**
* Print a tcp state for debugging purposes.
*

View File

@ -587,10 +587,10 @@ u16_t tcp_eff_send_mss(u16_t sendmss, struct ip_addr *addr);
extern struct tcp_pcb *tcp_input_pcb;
extern u32_t tcp_ticks;
const char* tcp_debug_state_str(enum tcp_state s);
#if TCP_DEBUG || TCP_INPUT_DEBUG || TCP_OUTPUT_DEBUG
void tcp_debug_print(struct tcp_hdr *tcphdr);
void tcp_debug_print_flags(u8_t flags);
const char* tcp_debug_state_str(enum tcp_state s);
void tcp_debug_print_state(enum tcp_state s);
void tcp_debug_print_pcbs(void);
s16_t tcp_pcbs_sane(void);