aboutsummaryrefslogtreecommitdiff
path: root/slirp/dhcpv6.c
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2018-11-22 02:06:41 +0400
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2019-01-14 23:36:38 +0100
commit226ea7a96485f2b9db13b523551c536dc68a1689 (patch)
treec2e90a49e934d31ca6e22678888e63c07785f856 /slirp/dhcpv6.c
parent2a2d3e4a258b9ed7ef5be7c6e421d58a365a0297 (diff)
downloadqemu-226ea7a96485f2b9db13b523551c536dc68a1689.zip
qemu-226ea7a96485f2b9db13b523551c536dc68a1689.tar.gz
qemu-226ea7a96485f2b9db13b523551c536dc68a1689.tar.bz2
slirp: call into g_debug() for DEBUG macros
Make slirp use GLib logging, instead of fprintf(), so that applications can filter log, process it etc. With recent versions of glib, G_MESSAGES_DEBUG must be set to "all" or "Slirp" to see slirp debug messages. Reformat DEBUG_MISC & DEBUG_ERROR calls to not need \n ending. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Diffstat (limited to 'slirp/dhcpv6.c')
-rw-r--r--slirp/dhcpv6.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/slirp/dhcpv6.c b/slirp/dhcpv6.c
index 5d703e8..752df40 100644
--- a/slirp/dhcpv6.c
+++ b/slirp/dhcpv6.c
@@ -92,13 +92,13 @@ static int dhcpv6_parse_info_request(Slirp *slirp, uint8_t *odata, int olen,
ri->want_boot_url = true;
break;
default:
- DEBUG_MISC("dhcpv6: Unsupported option request %d\n",
+ DEBUG_MISC("dhcpv6: Unsupported option request %d",
req_opt);
}
}
break;
default:
- DEBUG_MISC("dhcpv6 info req: Unsupported option %d, len=%d\n",
+ DEBUG_MISC("dhcpv6 info req: Unsupported option %d, len=%d",
option, len);
}
@@ -203,6 +203,6 @@ void dhcpv6_input(struct sockaddr_in6 *srcsas, struct mbuf *m)
dhcpv6_info_request(m->slirp, srcsas, xid, &data[4], data_len - 4);
break;
default:
- DEBUG_MISC("dhcpv6_input: Unsupported message type 0x%x\n", data[0]);
+ DEBUG_MISC("dhcpv6_input: Unsupported message type 0x%x", data[0]);
}
}