Joe Orton wrote: > > If the socket is bound to 0.0.0.0 then the local address of the socket > *is* known to be 0.0.0.0. There is no need to call getsockname() to > confirm that later, it can't change until _connect() is called, at which > point the existing code does already DTRT by setting the "unknown" flag > iff necessary.
How does that differ from the port being 0 == unknown in bind? Port 0 is ephemeral. IP 0.0.0.0 is ephemeral. I'm just not groking this design pattern (using the word design somewhat losely :) Why is the port_unknown set here then? The IP isn't 0.0.0.0, it's in fact a set of addresses of all of the bound adapters to 0.0.0.0. The current API doesn't lend itself very well though to untangling this.
