diff --git a/Makefile b/Makefile index c7a321110fe4335e9d220723320d7cedbf316b6f..74a1c6ff0352cebebac7213e77f91247ce9002a6 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,4 @@ +PROJ = fanout OBJS = CC = gcc DEBUG = -g @@ -7,7 +8,7 @@ LFLAGS = -Wall $(DEBUG) .PHONY : $(OBJS) fanout : - $(CC) $(LFLAGS) $(OBJS) -o fanout fanout.c + $(CC) $(LFLAGS) $(OBJS) -o $(PROJ) fanout.c clean: \rm fanout diff --git a/fanout.c b/fanout.c index 5a7cc1c7213b11088d2ec61a30603770438015c4..a49974ef96ebc8e3c38824d8c47758960dd745f2 100644 --- a/fanout.c +++ b/fanout.c @@ -20,6 +20,7 @@ #include <errno.h> #include <sys/epoll.h> + struct client { int fd; @@ -599,7 +600,7 @@ struct channel *get_channel (const char *channel_name) channel_i = channel_i->next; } - fanout_debug (2, "creating new channel\n"); + fanout_debug (2, "creating new channel %s\n", channel_name); if ((channel_i = calloc (1, sizeof (struct channel))) == NULL) { fanout_error ("memory error"); } @@ -615,7 +616,7 @@ struct channel *get_channel (const char *channel_name) void remove_channel (struct channel *c) { - fanout_debug (3, "removing unused channel %s\n", c->name); + fanout_debug (2, "removing unused channel %s\n", c->name); if (c->next != NULL) { c->next->previous = c->previous; }