]> rtime.felk.cvut.cz Git - frescor/frsh-forb.git/commitdiff
fwp: Unify newlines in error messages
authorMichal Sojka <sojka@os.inf.tu-dresden.de>
Thu, 8 Mar 2012 22:18:17 +0000 (23:18 +0100)
committerMichal Sojka <sojka@os.inf.tu-dresden.de>
Thu, 8 Mar 2012 22:18:17 +0000 (23:18 +0100)
src/fwp/fwp/lib/fwp/fwp_debug.h
src/fwp/fwp/lib/fwp/fwp_endpoint.c
src/fwp/fwp/lib/fwp/fwp_utils.c
src/fwp/fwp/lib/fwp/fwp_vres.c

index cbbe07414ed923845df2de80cdf9aa6406948b9c..6ceb4728576ff47b298e5d4567e8ecee52ea9bb6 100644 (file)
@@ -51,8 +51,8 @@
 
 extern UL_LOG_CUST(ulogd_fwp);
 
-#define FWP_DEBUG(fmt,args...) ul_logdeb("%s: " fmt, __func__ , ##args)
-#define FWP_ERROR(fmt,args...) ul_logerr("%s: " fmt, __func__ , ##args)
+#define FWP_DEBUG(fmt,args...) ul_logdeb("%s: " fmt "\n", __func__ , ##args)
+#define FWP_ERROR(fmt,args...) ul_logerr("%s: " fmt "\n", __func__ , ##args)
 
 
 #endif
index 6117d6ceae0f7812cbb4e701ec9aea705a99e7f2..a340d73b6d1f8d650b1a0117846308bb977ce389 100644 (file)
@@ -328,7 +328,7 @@ int fwp_receive_endpoint_create(unsigned int port,
                }
                
                if (listen(fwp_epoint->sockd, fwp_epoint->attr.max_connections)){
-                       FWP_ERROR("Error on listen call: %s\n", strerror(errno));
+                       FWP_ERROR("Error on listen call: %s", strerror(errno));
                        goto err;
                }
                
@@ -445,7 +445,7 @@ static int fwp_receive_endpoint_accept(struct fwp_endpoint *fwp_epoint)
                        &peer.addrlen);
        
        if (csockd < 0) {
-               FWP_ERROR("Error on accept: %s\n", strerror(errno));
+               FWP_ERROR("Error on accept: %s", strerror(errno));
                return errno;   
        }               
 
index 69cf356b0c096c47cd7dbdd9984b1cacd65321c9..7fbb11a710344a538094f98cd4b6a41195ed6afa 100644 (file)
@@ -99,13 +99,13 @@ int fwp_set_rt_prio(int priority)
        static struct sched_param param;
 
        if ((maxpri = sched_get_priority_max(SCHED_FIFO)) == -1) {
-               FWP_ERROR("sched_get_priority_max call failed: %s\n", 
+               FWP_ERROR("sched_get_priority_max call failed: %s", 
                                strerror(errno));
                return -1;
        }       
 
        if ((minpri = sched_get_priority_min(SCHED_FIFO)) == -1) {
-               FWP_ERROR("sched_get_priority_min call failed: %s\n", 
+               FWP_ERROR("sched_get_priority_min call failed: %s", 
                                strerror(errno));
                return -1;
        }
index 1078bd184f592e16b92704e32aa558b24a7d4d3f..92c15cb6e43954809d00a4bd04d986c900a22bdd 100644 (file)
@@ -401,7 +401,7 @@ static void send_queue(struct fwp_vres *vres)
        can_send = (0 == __consume_budget(vres, msgb->len, false));
        if (!can_send) {
                fwp_msgb_free(msgb);
-               FWP_ERROR("Cannot send queued packet (budget decreased?)\n");
+               FWP_ERROR("Cannot send queued packet (budget decreased?)");
                return;
        }
        /* If we cannot send the whole queue, the flag will be set