X-Git-Url: https://git.distorted.org.uk/~mdw/fwd/blobdiff_plain/47a7631fc173b345182df04f67523d3b2fe4ba83..755e6619263d316dc46fa504e0c333c963ec8eaa:/un.c diff --git a/un.c b/un.c index 60d1cc4..1ee5363 100644 --- a/un.c +++ b/un.c @@ -7,24 +7,24 @@ /*----- Licensing notice --------------------------------------------------* * - * This file is part of the `fw' port forwarder. + * This file is part of the `fwd' port forwarder. * - * `fw' is free software; you can redistribute it and/or modify + * `fwd' is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * - * `fw' is distributed in the hope that it will be useful, + * `fwd' is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License - * along with `fw'; if not, write to the Free Software Foundation, + * along with `fwd'; if not, write to the Free Software Foundation, * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "fw.h" +#include "fwd.h" /*----- Data structures ---------------------------------------------------*/ @@ -47,7 +47,7 @@ static addr *un_read(scanner *sc, unsigned type) dstr d = DSTR_INIT; un_addr *ua; - conf_name(sc, '/', &d); + conf_fname(sc, &d); ua = xmalloc(sizeof(addr) + offsetof(struct sockaddr_un, sun_path) + d.len + 1); @@ -119,7 +119,7 @@ static reffd *un_accept(int fd, addr_opts *ao, const char *desc) { char buf[PATH_MAX + sizeof(struct sockaddr)]; struct sockaddr_un *sun = (struct sockaddr_un *)buf; - size_t sunsz = sizeof(buf); + socklen_t sunsz = sizeof(buf); if ((nfd = accept(fd, (struct sockaddr *)sun, &sunsz)) < 0) return (0);