On 19 May 2015 at 16:03, Mikio Hara <
mikioh...@gmail.com> wrote:
> On Tue, May 19, 2015 at 11:54 PM, roger peppe <
rogp...@gmail.com> wrote:
>
>> I started off doing that, but much of the code expects to pass
>> the address to a sockaddr parameter
>
> We cannot break plan9 build.
How would this break the plan9 build?
>>> This occurs when a) a setup fails before booking its name, b) an
>>> underlying protocol doesn't support endpoint name. Do you have any
>>> opinions how should we represent a wildcard address in the case of (a)
>>> and (b) ?
>>
>> I'm don't understand this, sorry.
>
> When we kick DialTCP("tcp", nil, &TCPAddr{Port: 5963}), should we
> return either a) OpError{Source: nil, Addr: &TCPAddr{Port: 5963}}, or
> b) OpError{Source: &TCPAddr{}, Addr: &TCPAddr{Port: 5963}} ?
>
> I guess you'd prefer the former, right?
I don't mind either way. What I *don't* want to see (and what
is happening now) is that we're getting:
OpError{Source: (*TCPAddr)(nil), Addr: &TCPAddr{Port: 5963}}
> When we invoke ListenTCP("tcp", nil, &TCPAddr{}), should we return
> either a) OpError{Source: nil, Addr: &TCPAddr{}}, or b)
> OpError{Source: nil, Addr: nil}} ?
>
> I’d prefer the former but also fine with the latter.
Definitely the former, as that's what we passed in.
But, to reiterate, not OpError{Source: (*TCPAddr)(nil), Addr: &TCPAddr{}}
which is what we get now.