added flag for enabling debug messages, without debug messages only connection events are displayed

This commit is contained in:
Igor Socec 2014-03-20 12:13:52 +01:00
parent 1001f3ad9c
commit 91becdad1c
3 changed files with 21 additions and 14 deletions

View file

@ -35,7 +35,7 @@ int client_read(struct client_t *client) {
}
//TODO let's print received bytes during development phase...
{
if (debug_messages) {
int i;
for(i = 0; i < len; i++) {
fprintf(stderr, "client %s <- %u '%c'\n",
@ -63,7 +63,7 @@ int client_write(struct client_t *client, char *databuf, int datalen) {
//telnet_handle_client_write(databuf, &datalen);
//TODO let's print received bytes during development phase...
{
if (debug_messages) {
int i;
for(i = 0; i < datalen; i++) {
fprintf(stderr, "client %s -> %u '%c'\n",