From f84076b112209a1c720cb5df213596327f04507f Mon Sep 17 00:00:00 2001 From: Shawn Silverman Date: Sun, 9 Apr 2023 10:29:10 -0700 Subject: [PATCH] Add missing terminating newlines to LWIP_DEBUGF statements --- contrib/apps/httpserver/httpserver-netconn.c | 2 +- contrib/ports/unix/port/sys_arch.c | 2 +- src/api/sockets.c | 2 +- src/apps/altcp_tls/altcp_tls_mbedtls.c | 14 +++++++------- src/apps/altcp_tls/altcp_tls_mbedtls_mem.c | 4 ++-- src/apps/http/httpd.c | 2 +- src/apps/mdns/mdns.c | 6 ++++-- src/apps/snmp/snmp_msg.c | 6 ++++-- src/apps/snmp/snmp_threadsync.c | 2 +- src/apps/snmp/snmp_traps.c | 2 +- src/core/dns.c | 4 ++-- src/core/ipv4/autoip.c | 8 ++++---- src/core/ipv4/dhcp.c | 2 +- src/core/ipv4/icmp.c | 6 +++--- src/core/ipv4/ip4.c | 2 +- src/core/ipv6/dhcp6.c | 8 ++++---- src/core/raw.c | 1 + src/netif/bridgeif.c | 2 +- src/netif/ethernet.c | 4 ++-- src/netif/lowpan6_common.c | 4 ++-- 20 files changed, 44 insertions(+), 39 deletions(-) diff --git a/contrib/apps/httpserver/httpserver-netconn.c b/contrib/apps/httpserver/httpserver-netconn.c index 36f5ad85..051584e6 100644 --- a/contrib/apps/httpserver/httpserver-netconn.c +++ b/contrib/apps/httpserver/httpserver-netconn.c @@ -87,7 +87,7 @@ http_server_netconn_thread(void *arg) } } while(err == ERR_OK); LWIP_DEBUGF(HTTPD_DEBUG, - ("http_server_netconn_thread: netconn_accept received error %d, shutting down", + ("http_server_netconn_thread: netconn_accept received error %d, shutting down\n", err)); netconn_close(conn); netconn_delete(conn); diff --git a/contrib/ports/unix/port/sys_arch.c b/contrib/ports/unix/port/sys_arch.c index 10c22023..1e094e80 100644 --- a/contrib/ports/unix/port/sys_arch.c +++ b/contrib/ports/unix/port/sys_arch.c @@ -215,7 +215,7 @@ sys_thread_new(const char *name, lwip_thread_fn function, void *arg, int stacksi } if (NULL == st) { - LWIP_DEBUGF(SYS_DEBUG, ("sys_thread_new: pthread_create %d, st = 0x%lx", + LWIP_DEBUGF(SYS_DEBUG, ("sys_thread_new: pthread_create %d, st = 0x%lx\n", code, (unsigned long)st)); abort(); } diff --git a/src/api/sockets.c b/src/api/sockets.c index 50365589..b9111943 100644 --- a/src/api/sockets.c +++ b/src/api/sockets.c @@ -743,7 +743,7 @@ lwip_accept(int s, struct sockaddr *addr, socklen_t *addrlen) ip_addr_debug_print_val(SOCKETS_DEBUG, naddr); LWIP_DEBUGF(SOCKETS_DEBUG, (" port=%"U16_F"\n", port)); } else { - LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_accept(%d) returning new sock=%d", s, newsock)); + LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_accept(%d) returning new sock=%d\n", s, newsock)); } set_errno(0); diff --git a/src/apps/altcp_tls/altcp_tls_mbedtls.c b/src/apps/altcp_tls/altcp_tls_mbedtls.c index ee3eee5c..a8c2fc2e 100644 --- a/src/apps/altcp_tls/altcp_tls_mbedtls.c +++ b/src/apps/altcp_tls/altcp_tls_mbedtls.c @@ -717,7 +717,7 @@ altcp_mbedtls_debug(void *ctx, int level, const char *file, int line, const char LWIP_UNUSED_ARG(str); if (level >= ALTCP_MBEDTLS_LIB_DEBUG_LEVEL_MIN) { - LWIP_DEBUGF(ALTCP_MBEDTLS_LIB_DEBUG, ("%s:%04d: %s", file, line, str)); + LWIP_DEBUGF(ALTCP_MBEDTLS_LIB_DEBUG, ("%s:%04d: %s\n", file, line, str)); } } #endif @@ -959,7 +959,7 @@ altcp_tls_create_config_client_common(const u8_t *ca, size_t ca_len, int is_2way mbedtls_x509_crt_init(conf->ca); ret = mbedtls_x509_crt_parse(conf->ca, ca, ca_len); if (ret != 0) { - LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("mbedtls_x509_crt_parse ca failed: %d 0x%x", ret, -1*ret)); + LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("mbedtls_x509_crt_parse ca failed: %d 0x%x\n", ret, -1*ret)); altcp_tls_free_config(conf); return NULL; } @@ -984,7 +984,7 @@ altcp_tls_create_config_client_2wayauth(const u8_t *ca, size_t ca_len, const u8_ struct altcp_tls_config *conf; if (!cert || !privkey) { - LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("altcp_tls_create_config_client_2wayauth: certificate and priv key required")); + LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("altcp_tls_create_config_client_2wayauth: certificate and priv key required\n")); return NULL; } @@ -997,7 +997,7 @@ altcp_tls_create_config_client_2wayauth(const u8_t *ca, size_t ca_len, const u8_ mbedtls_x509_crt_init(conf->cert); ret = mbedtls_x509_crt_parse(conf->cert, cert, cert_len); if (ret != 0) { - LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("mbedtls_x509_crt_parse cert failed: %d 0x%x", ret, -1*ret)); + LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("mbedtls_x509_crt_parse cert failed: %d 0x%x\n", ret, -1*ret)); altcp_tls_free_config(conf); return NULL; } @@ -1005,14 +1005,14 @@ altcp_tls_create_config_client_2wayauth(const u8_t *ca, size_t ca_len, const u8_ mbedtls_pk_init(conf->pkey); ret = mbedtls_pk_parse_key(conf->pkey, privkey, privkey_len, privkey_pass, privkey_pass_len); if (ret != 0) { - LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("mbedtls_pk_parse_key failed: %d 0x%x", ret, -1*ret)); + LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("mbedtls_pk_parse_key failed: %d 0x%x\n", ret, -1*ret)); altcp_tls_free_config(conf); return NULL; } ret = mbedtls_ssl_conf_own_cert(&conf->conf, conf->cert, conf->pkey); if (ret != 0) { - LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("mbedtls_ssl_conf_own_cert failed: %d 0x%x", ret, -1*ret)); + LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("mbedtls_ssl_conf_own_cert failed: %d 0x%x\n", ret, -1*ret)); altcp_tls_free_config(conf); return NULL; } @@ -1091,7 +1091,7 @@ altcp_mbedtls_recved(struct altcp_pcb *conn, u16_t len) } lower_recved = len; if (lower_recved > state->rx_passed_unrecved) { - LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("bogus recved count (len > state->rx_passed_unrecved / %d / %d)", + LWIP_DEBUGF(ALTCP_MBEDTLS_DEBUG, ("bogus recved count (len > state->rx_passed_unrecved / %d / %d)\n", len, state->rx_passed_unrecved)); lower_recved = (u16_t)state->rx_passed_unrecved; } diff --git a/src/apps/altcp_tls/altcp_tls_mbedtls_mem.c b/src/apps/altcp_tls/altcp_tls_mbedtls_mem.c index 9bc7f465..d2c3d58d 100644 --- a/src/apps/altcp_tls/altcp_tls_mbedtls_mem.c +++ b/src/apps/altcp_tls/altcp_tls_mbedtls_mem.c @@ -114,13 +114,13 @@ tls_malloc(size_t c, size_t len) alloc_size = sizeof(altcp_mbedtls_malloc_helper_t) + (c * len); /* check for maximum allocation size, mainly to prevent mem_size_t overflow */ if (alloc_size > MEM_SIZE) { - LWIP_DEBUGF(ALTCP_MBEDTLS_MEM_DEBUG, ("mbedtls allocation too big: %c * %d bytes vs MEM_SIZE=%d", + LWIP_DEBUGF(ALTCP_MBEDTLS_MEM_DEBUG, ("mbedtls allocation too big: %c * %d bytes vs MEM_SIZE=%d\n", (int)c, (int)len, (int)MEM_SIZE)); return NULL; } hlpr = (altcp_mbedtls_malloc_helper_t *)mem_malloc((mem_size_t)alloc_size); if (hlpr == NULL) { - LWIP_DEBUGF(ALTCP_MBEDTLS_MEM_DEBUG, ("mbedtls alloc callback failed for %c * %d bytes", (int)c, (int)len)); + LWIP_DEBUGF(ALTCP_MBEDTLS_MEM_DEBUG, ("mbedtls alloc callback failed for %c * %d bytes\n", (int)c, (int)len)); return NULL; } #if ALTCP_MBEDTLS_PLATFORM_ALLOC_STATS diff --git a/src/apps/http/httpd.c b/src/apps/http/httpd.c index bcf4b25f..9477e855 100644 --- a/src/apps/http/httpd.c +++ b/src/apps/http/httpd.c @@ -2450,7 +2450,7 @@ http_err(void *arg, err_t err) struct http_state *hs = (struct http_state *)arg; LWIP_UNUSED_ARG(err); - LWIP_DEBUGF(HTTPD_DEBUG, ("http_err: %s", lwip_strerr(err))); + LWIP_DEBUGF(HTTPD_DEBUG, ("http_err: %s\n", lwip_strerr(err))); if (hs != NULL) { http_state_free(hs); diff --git a/src/apps/mdns/mdns.c b/src/apps/mdns/mdns.c index 915908f0..80c3c6ef 100644 --- a/src/apps/mdns/mdns.c +++ b/src/apps/mdns/mdns.c @@ -672,8 +672,10 @@ mdns_lexicographical_comparison(struct mdns_packet *pkt_a, struct mdns_packet *p } LWIP_DEBUGF(MDNS_DEBUG, ("mDNS: domain a: len = %d, name = ", domain_a.name[0])); mdns_domain_debug_print(&domain_a); + LWIP_DEBUGF(MDNS_DEBUG, ("\n")); LWIP_DEBUGF(MDNS_DEBUG, ("mDNS: domain b: len = %d, name = ", domain_b.name[0])); mdns_domain_debug_print(&domain_b); + LWIP_DEBUGF(MDNS_DEBUG, ("\n")); /* Compare names pairwise */ len = LWIP_MIN(domain_a.length, domain_b.length); for (i = 0; i < len; i++) { @@ -1935,7 +1937,7 @@ mdns_handle_response(struct mdns_packet *pkt, struct netif *netif) res = mdns_build_host_domain(&domain, mdns); if (res == ERR_OK && mdns_domain_eq(&ans.info.domain, &domain)) { - LWIP_DEBUGF(MDNS_DEBUG, ("MDNS: Probe response matches host domain!")); + LWIP_DEBUGF(MDNS_DEBUG, ("MDNS: Probe response matches host domain!\n")); mdns_probe_conflict(netif, 0); break; } @@ -1947,7 +1949,7 @@ mdns_handle_response(struct mdns_packet *pkt, struct netif *netif) } res = mdns_build_service_domain(&domain, service, 1); if ((res == ERR_OK) && mdns_domain_eq(&ans.info.domain, &domain)) { - LWIP_DEBUGF(MDNS_DEBUG, ("MDNS: Probe response matches service domain!")); + LWIP_DEBUGF(MDNS_DEBUG, ("MDNS: Probe response matches service domain!\n")); mdns_probe_conflict(netif, i + 1); break; } diff --git a/src/apps/snmp/snmp_msg.c b/src/apps/snmp/snmp_msg.c index d0f490b3..9cd4b071 100644 --- a/src/apps/snmp/snmp_msg.c +++ b/src/apps/snmp/snmp_msg.c @@ -647,7 +647,7 @@ snmp_process_getbulk_request(struct snmp_request *request) /* no more varbinds in request */ break; } else { - LWIP_DEBUGF(SNMP_DEBUG, ("Very strange, we cannot parse the varbind output that we created just before!")); + LWIP_DEBUGF(SNMP_DEBUG, ("Very strange, we cannot parse the varbind output that we created just before!\n")); request->error_status = SNMP_ERR_GENERROR; request->error_index = request->non_repeaters + repetition_varbind_enumerator.varbind_count; } @@ -765,6 +765,7 @@ snmp_process_set_request(struct snmp_request *request) #define PARSE_ASSERT(cond, retValue) \ if (!(cond)) { \ LWIP_DEBUGF(SNMP_DEBUG, ("SNMP parse assertion failed!: " # cond)); \ + LWIP_DEBUGF(SNMP_DEBUG, ("\n")); \ snmp_stats.inasnparseerrs++; \ return retValue; \ } @@ -772,6 +773,7 @@ snmp_process_set_request(struct snmp_request *request) #define BUILD_EXEC(code, retValue) \ if ((code) != ERR_OK) { \ LWIP_DEBUGF(SNMP_DEBUG, ("SNMP error during creation of outbound frame!: " # code)); \ + LWIP_DEBUGF(SNMP_DEBUG, ("\n")); \ return retValue; \ } @@ -1204,7 +1206,7 @@ snmp_parse_inbound_frame(struct snmp_request *request) break; default: /* unsupported input PDU for this agent (no parse error) */ - LWIP_DEBUGF(SNMP_DEBUG, ("Unknown/Invalid SNMP PDU type received: %d", tlv.type)); \ + LWIP_DEBUGF(SNMP_DEBUG, ("Unknown/Invalid SNMP PDU type received: %d\n", tlv.type)); \ return ERR_ARG; } request->request_type = tlv.type & SNMP_ASN1_DATATYPE_MASK; diff --git a/src/apps/snmp/snmp_threadsync.c b/src/apps/snmp/snmp_threadsync.c index 56d98862..927c62a0 100644 --- a/src/apps/snmp/snmp_threadsync.c +++ b/src/apps/snmp/snmp_threadsync.c @@ -176,7 +176,7 @@ do_sync(const u32_t *root_oid, u8_t root_oid_len, struct snmp_node_instance *ins struct threadsync_data *call_data = &threadsync_node->instance->data; if (threadsync_node->node.node.oid != threadsync_node->target->node.oid) { - LWIP_DEBUGF(SNMP_DEBUG, ("Sync node OID does not match target node OID")); + LWIP_DEBUGF(SNMP_DEBUG, ("Sync node OID does not match target node OID\n")); return SNMP_ERR_NOSUCHINSTANCE; } diff --git a/src/apps/snmp/snmp_traps.c b/src/apps/snmp/snmp_traps.c index 724a45d8..4acbe604 100644 --- a/src/apps/snmp/snmp_traps.c +++ b/src/apps/snmp/snmp_traps.c @@ -101,7 +101,7 @@ static err_t snmp_send_msg(struct snmp_msg_trap *trap_msg, struct snmp_varbind * #define BUILD_EXEC(code) \ if ((code) != ERR_OK) { \ - LWIP_DEBUGF(SNMP_DEBUG, ("SNMP error during creation of outbound trap frame!")); \ + LWIP_DEBUGF(SNMP_DEBUG, ("SNMP error during creation of outbound trap frame!\n")); \ return ERR_ARG; \ } diff --git a/src/core/dns.c b/src/core/dns.c index e84bab24..6540f143 100644 --- a/src/core/dns.c +++ b/src/core/dns.c @@ -487,7 +487,7 @@ dns_local_lookup(const char *hostname, ip_addr_t *addr, u8_t dns_addrtype) hostnamelen--; } if (hostnamelen >= DNS_MAX_NAME_LENGTH) { - LWIP_DEBUGF(DNS_DEBUG, ("dns_local_lookup: name too long to resolve")); + LWIP_DEBUGF(DNS_DEBUG, ("dns_local_lookup: name too long to resolve\n")); return ERR_ARG; } return dns_lookup_local(hostname, hostnamelen, addr LWIP_DNS_ADDRTYPE_ARG(dns_addrtype)); @@ -1590,7 +1590,7 @@ dns_gethostbyname_addrtype(const char *hostname, ip_addr_t *addr, dns_found_call hostnamelen--; } if (hostnamelen >= DNS_MAX_NAME_LENGTH) { - LWIP_DEBUGF(DNS_DEBUG, ("dns_gethostbyname: name too long to resolve")); + LWIP_DEBUGF(DNS_DEBUG, ("dns_gethostbyname: name too long to resolve\n")); return ERR_ARG; } diff --git a/src/core/ipv4/autoip.c b/src/core/ipv4/autoip.c index 869bf9b5..461a0053 100644 --- a/src/core/ipv4/autoip.c +++ b/src/core/ipv4/autoip.c @@ -260,7 +260,7 @@ autoip_start(struct netif *netif) } /* store this AutoIP client in the netif */ netif_set_client_data(netif, LWIP_NETIF_CLIENT_DATA_INDEX_AUTOIP, autoip); - LWIP_DEBUGF(AUTOIP_DEBUG | LWIP_DBG_TRACE, ("autoip_start(): allocated autoip")); + LWIP_DEBUGF(AUTOIP_DEBUG | LWIP_DBG_TRACE, ("autoip_start(): allocated autoip\n")); } if (autoip->state == AUTOIP_STATE_OFF) { @@ -304,7 +304,7 @@ autoip_network_changed_link_up(struct netif *netif) if (autoip && (autoip->state != AUTOIP_STATE_OFF) && !LWIP_DHCP_AUTOIP_COOP) { LWIP_DEBUGF(AUTOIP_DEBUG | LWIP_DBG_TRACE, - ("autoip_network_changed_link_up(): start acd")); + ("autoip_network_changed_link_up(): start acd\n")); autoip->state = AUTOIP_STATE_CHECKING; /* Start acd check again for the last used address */ acd_start(netif, &autoip->acd, autoip->llipaddr); @@ -325,7 +325,7 @@ autoip_network_changed_link_down(struct netif *netif) if (autoip && (autoip->state != AUTOIP_STATE_OFF) && LWIP_DHCP_AUTOIP_COOP) { LWIP_DEBUGF(AUTOIP_DEBUG | LWIP_DBG_TRACE, - ("autoip_network_changed_link_down(): stop autoip")); + ("autoip_network_changed_link_down(): stop autoip\n")); autoip_stop(netif); } } @@ -347,7 +347,7 @@ autoip_stop(struct netif *netif) if (ip4_addr_islinklocal(netif_ip4_addr(netif))) { netif_set_addr(netif, IP4_ADDR_ANY4, IP4_ADDR_ANY4, IP4_ADDR_ANY4); } - LWIP_DEBUGF(AUTOIP_DEBUG | LWIP_DBG_TRACE,("autoip_stop()")); + LWIP_DEBUGF(AUTOIP_DEBUG | LWIP_DBG_TRACE,("autoip_stop()\n")); } return ERR_OK; } diff --git a/src/core/ipv4/dhcp.c b/src/core/ipv4/dhcp.c index 920b6c99..32f6611c 100644 --- a/src/core/ipv4/dhcp.c +++ b/src/core/ipv4/dhcp.c @@ -1576,7 +1576,7 @@ again: } else { len = (q->next != NULL ? ((u8_t *)q->next->payload)[0] : 0); } - /* LWIP_DEBUGF(DHCP_DEBUG, ("msg_offset=%"U16_F", q->len=%"U16_F, msg_offset, q->len)); */ + /* LWIP_DEBUGF(DHCP_DEBUG, ("msg_offset=%"U16_F", q->len=%"U16_F"\n", msg_offset, q->len)); */ decode_len = len; switch (op) { /* case(DHCP_OPTION_END): handled above */ diff --git a/src/core/ipv4/icmp.c b/src/core/ipv4/icmp.c index 9810b9bb..9d64bba3 100644 --- a/src/core/ipv4/icmp.c +++ b/src/core/ipv4/icmp.c @@ -171,7 +171,7 @@ icmp_input(struct pbuf *p, struct netif *inp) goto icmperr; } if (r->len < hlen + sizeof(struct icmp_echo_hdr)) { - LWIP_DEBUGF(ICMP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("first pbuf cannot hold the ICMP header")); + LWIP_DEBUGF(ICMP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("first pbuf cannot hold the ICMP header\n")); pbuf_free(r); goto icmperr; } @@ -185,7 +185,7 @@ icmp_input(struct pbuf *p, struct netif *inp) } /* copy the rest of the packet without ip header */ if (pbuf_copy(r, p) != ERR_OK) { - LWIP_DEBUGF(ICMP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("icmp_input: copying to new pbuf failed")); + LWIP_DEBUGF(ICMP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("icmp_input: copying to new pbuf failed\n")); pbuf_free(r); goto icmperr; } @@ -206,7 +206,7 @@ icmp_input(struct pbuf *p, struct netif *inp) * setting the icmp type to ECHO_RESPONSE and updating the checksum. */ iecho = (struct icmp_echo_hdr *)p->payload; if (pbuf_add_header(p, hlen)) { - LWIP_DEBUGF(ICMP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("Can't move over header in packet")); + LWIP_DEBUGF(ICMP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("Can't move over header in packet\n")); } else { err_t ret; struct ip_hdr *iphdr = (struct ip_hdr *)p->payload; diff --git a/src/core/ipv4/ip4.c b/src/core/ipv4/ip4.c index 36f32358..e044bff2 100644 --- a/src/core/ipv4/ip4.c +++ b/src/core/ipv4/ip4.c @@ -1021,7 +1021,7 @@ ip4_output_if_opt_src(struct pbuf *p, const ip4_addr_t *src, const ip4_addr_t *d #endif /* !LWIP_HAVE_LOOPIF */ ) { /* Packet to self, enqueue it for loopback */ - LWIP_DEBUGF(IP_DEBUG, ("netif_loop_output()")); + LWIP_DEBUGF(IP_DEBUG, ("netif_loop_output()\n")); return netif_loop_output(netif, p); } #if LWIP_MULTICAST_TX_OPTIONS diff --git a/src/core/ipv6/dhcp6.c b/src/core/ipv6/dhcp6.c index ecf569a8..e6a7e64d 100644 --- a/src/core/ipv6/dhcp6.c +++ b/src/core/ipv6/dhcp6.c @@ -240,7 +240,7 @@ dhcp6_get_struct(struct netif *netif, const char *dbg_requester) netif_set_client_data(netif, LWIP_NETIF_CLIENT_DATA_INDEX_DHCP6, NULL); return NULL; } - LWIP_DEBUGF(DHCP6_DEBUG | LWIP_DBG_TRACE, ("%s: allocated dhcp6", dbg_requester)); + LWIP_DEBUGF(DHCP6_DEBUG | LWIP_DBG_TRACE, ("%s: allocated dhcp6\n", dbg_requester)); dhcp6->pcb_allocated = 1; } return dhcp6; @@ -299,7 +299,7 @@ err_t dhcp6_enable_stateful(struct netif *netif) { LWIP_UNUSED_ARG(netif); - LWIP_DEBUGF(DHCP6_DEBUG | LWIP_DBG_TRACE, ("stateful dhcp6 not implemented yet")); + LWIP_DEBUGF(DHCP6_DEBUG | LWIP_DBG_TRACE, ("stateful dhcp6 not implemented yet\n")); return ERR_VAL; } @@ -324,12 +324,12 @@ dhcp6_enable_stateless(struct netif *netif) return ERR_MEM; } if (dhcp6_stateless_enabled(dhcp6)) { - LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp6_enable_stateless(): stateless DHCPv6 already enabled")); + LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp6_enable_stateless(): stateless DHCPv6 already enabled\n")); return ERR_OK; } else if (dhcp6->state != DHCP6_STATE_OFF) { /* stateful running */ /* @todo: stop stateful once it is implemented */ - LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp6_enable_stateless(): switching from stateful to stateless DHCPv6")); + LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp6_enable_stateless(): switching from stateful to stateless DHCPv6\n")); } LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp6_enable_stateless(): stateless DHCPv6 enabled\n")); dhcp6_set_state(dhcp6, DHCP6_STATE_STATELESS_IDLE, "dhcp6_enable_stateless"); diff --git a/src/core/raw.c b/src/core/raw.c index 40a442a7..94e299a5 100644 --- a/src/core/raw.c +++ b/src/core/raw.c @@ -384,6 +384,7 @@ raw_sendto(struct raw_pcb *pcb, struct pbuf *p, const ip_addr_t *ipaddr) if (netif == NULL) { LWIP_DEBUGF(RAW_DEBUG | LWIP_DBG_LEVEL_WARNING, ("raw_sendto: No route to ")); ip_addr_debug_print(RAW_DEBUG | LWIP_DBG_LEVEL_WARNING, ipaddr); + LWIP_DEBUGF(RAW_DEBUG | LWIP_DBG_LEVEL_WARNING, ("\n")); return ERR_RTE; } diff --git a/src/netif/bridgeif.c b/src/netif/bridgeif.c index 021922f6..2dc88fc9 100644 --- a/src/netif/bridgeif.c +++ b/src/netif/bridgeif.c @@ -421,7 +421,7 @@ bridgeif_init(struct netif *netif) LWIP_ASSERT("bridgeif needs an input callback", (netif->input != NULL)); #if !BRIDGEIF_PORT_NETIFS_OUTPUT_DIRECT if (netif->input == tcpip_input) { - LWIP_DEBUGF(BRIDGEIF_DEBUG | LWIP_DBG_ON, ("bridgeif does not need tcpip_input, use netif_input/ethernet_input instead")); + LWIP_DEBUGF(BRIDGEIF_DEBUG | LWIP_DBG_ON, ("bridgeif does not need tcpip_input, use netif_input/ethernet_input instead\n")); } #endif diff --git a/src/netif/ethernet.c b/src/netif/ethernet.c index b33566bd..db5c514b 100644 --- a/src/netif/ethernet.c +++ b/src/netif/ethernet.c @@ -179,7 +179,7 @@ ethernet_input(struct pbuf *p, struct netif *netif) LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("ethernet_input: IPv4 packet dropped, too short (%"U16_F"/%"U16_F")\n", p->tot_len, next_hdr_offset)); - LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("Can't move over header in packet")); + LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("Can't move over header in packet\n")); goto free_and_return; } else { /* pass to IP layer */ @@ -196,7 +196,7 @@ ethernet_input(struct pbuf *p, struct netif *netif) LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("ethernet_input: ARP response packet dropped, too short (%"U16_F"/%"U16_F")\n", p->tot_len, next_hdr_offset)); - LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("Can't move over header in packet")); + LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("Can't move over header in packet\n")); ETHARP_STATS_INC(etharp.lenerr); ETHARP_STATS_INC(etharp.drop); goto free_and_return; diff --git a/src/netif/lowpan6_common.c b/src/netif/lowpan6_common.c index 01b62dfd..9f50658a 100644 --- a/src/netif/lowpan6_common.c +++ b/src/netif/lowpan6_common.c @@ -424,7 +424,7 @@ lowpan6_decompress_hdr(u8_t *lowpan6_buffer, size_t lowpan6_bufsize, } LWIP_DEBUGF(LWIP_LOWPAN6_IP_COMPRESSED_DEBUG, ("%2X ", lowpan6_buffer[j])); } - LWIP_DEBUGF(LWIP_LOWPAN6_IP_COMPRESSED_DEBUG, ("\np->len: %d", lowpan6_bufsize)); + LWIP_DEBUGF(LWIP_LOWPAN6_IP_COMPRESSED_DEBUG, ("\np->len: %d\n", lowpan6_bufsize)); } #endif @@ -667,7 +667,7 @@ lowpan6_decompress_hdr(u8_t *lowpan6_buffer, size_t lowpan6_bufsize, /* M=0, DAC=0, determining destination address length via DAM=xx */ if ((lowpan6_buffer[1] & 0x03) == 0x00) { - LWIP_DEBUGF(LWIP_LOWPAN6_DECOMPRESSION_DEBUG, ("DAM == 00, no dst compression, fetching 128bits inline")); + LWIP_DEBUGF(LWIP_LOWPAN6_DECOMPRESSION_DEBUG, ("DAM == 00, no dst compression, fetching 128bits inline\n")); /* DAM=00, copy full address */ MEMCPY(&ip6hdr->dest.addr[0], lowpan6_buffer + lowpan6_offset, 16); lowpan6_offset += 16;