]> rtime.felk.cvut.cz Git - frescor/fwp.git/blobdiff - wme_test/wserver.c
Pridana DEBUG podminka do wserver
[frescor/fwp.git] / wme_test / wserver.c
index f42b0d297495d4d900d069b199c8c24da95a5eff..93ad509e67a3927bfd56cfcaa1dfa57862c21f80 100644 (file)
@@ -18,6 +18,9 @@
 #define        BUFFSIZE        65536
 #define AC_QUEUES      4
 
+/* Turn on/off debugging */
+#define DEBUG 0
+
 const int prio_to_ac[8] = {2,3,3,2,1,1,0,0};
 const unsigned int ac_to_tos[4] = {224,160,96,64};
 int ac_sockfd[AC_QUEUES];
@@ -92,9 +95,10 @@ void* qhandler(void* queue)
                            return NULL;
                }
 
+#if DEBUG
                printf("%d",ac);
                fflush(stdout);
-               
+#endif 
                while (sendto(ac_sockfd[ac], buff, mlen,0 ,(struct sockaddr*)&rem_addr, \
                        sizeof(rem_addr)) < 0){
                            if (errno == EINTR) continue;