Commit 5b996ab8 authored by Max Kellermann's avatar Max Kellermann

output/httpd: access sockaddr_storage object directly

Work around aliasing warning.
parent 635cfbae
...@@ -213,9 +213,8 @@ httpd_listen_in_event(G_GNUC_UNUSED GIOChannel *source, ...@@ -213,9 +213,8 @@ httpd_listen_in_event(G_GNUC_UNUSED GIOChannel *source,
fd = accept_cloexec_nonblock(httpd->fd, (struct sockaddr*)&sa, fd = accept_cloexec_nonblock(httpd->fd, (struct sockaddr*)&sa,
&sa_length); &sa_length);
#ifdef HAVE_LIBWRAP #ifdef HAVE_LIBWRAP
struct sockaddr *sa_p = (struct sockaddr *)&sa; if (sa.ss_family != AF_UNIX) {
if (sa_p->sa_family != AF_UNIX) { char *hostaddr = sockaddr_to_string((const struct sockaddr *)&sa, sa_length, NULL);
char *hostaddr = sockaddr_to_string(sa_p, sa_length, NULL);
const char *progname = g_get_prgname(); const char *progname = g_get_prgname();
struct request_info req; struct request_info req;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment