examples: add flush after stats printing
[dpdk.git] / examples / l2fwd / main.c
index 09257aa..4a41aac 100644 (file)
@@ -146,6 +146,8 @@ print_stats(void)
                   total_packets_rx,
                   total_packets_dropped);
        printf("\n====================================================\n");
+
+       fflush(stdout);
 }
 
 static void
@@ -281,7 +283,7 @@ l2fwd_main_loop(void)
 }
 
 static int
-l2fwd_launch_one_lcore(__attribute__((unused)) void *dummy)
+l2fwd_launch_one_lcore(__rte_unused void *dummy)
 {
        l2fwd_main_loop();
        return 0;
@@ -478,7 +480,7 @@ check_all_ports_link_status(uint32_t port_mask)
                                        "Port%d Link Up. Speed %u Mbps - %s\n",
                                                portid, link.link_speed,
                                (link.link_duplex == ETH_LINK_FULL_DUPLEX) ?
-                                       ("full-duplex") : ("half-duplex\n"));
+                                       ("full-duplex") : ("half-duplex"));
                                else
                                        printf("Port %d Link Down\n", portid);
                                continue;