|
|
Message-ID: <20140630020311.GD179@brightrain.aerifal.cx>
Date: Sun, 29 Jun 2014 22:03:11 -0400
From: Rich Felker <dalias@...c.org>
To: musl@...ts.openwall.com
Cc: alpine-devel@...ts.alpinelinux.org
Subject: Re: cups debugging, continued
On Sun, Jun 29, 2014 at 06:28:31PM -0700, Isaac Dunham wrote:
> On Sun, Jun 29, 2014 at 05:12:01PM -0700, Isaac Dunham wrote:
> > Now I hit the next issue: the 'lpd' backend reports
> > 'Unable to reserve port: Invalid argument'
> > And I need to figure out what's causing this--or rather, what the solution is.
> > Right now, I'm stuck (lpd is the main way to access it, and it isn't working).
> OK, now we're in cups-1.7.3/backend/lpd.c:
>
> ....the problem is a local implementation of rresvport_af(), trying to reserve
> a port but failing.
>
> And strace -p `pidof lpd` says this:
> Process 16113 attached
> restart_syscall(<... resuming interrupted call ...>) = 0
> geteuid32() = 0
> socket(PF_INET, SOCK_STREAM, IPPROTO_IP) = 7
> bind(7, {sa_family=AF_INET, sin_port=htons(905), sin_addr=inet_addr("0.0.0.0")}, 256) = -1 EINVAL (Invalid argument)
Where did the value of 256 for socklen_t come from? That's almost
surely the cause of the EINVAL. sockaddr_in should have a length of
16, not 256.
Rich
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.