You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by "William A. Rowe, Jr." <wr...@rowe-clan.net> on 2007/10/15 08:17:46 UTC

Bug to fix or not in 1.2.x - recvfrom?

[more details about that universal recvfrom issue in my prior note, I thought
I had sent this hours ago...]

     apr_sockaddr_ip_get(&ip_addr, from);
     fromport = from->port;
     ABTS_STR_EQUAL(tc, addr, ip_addr);
     ABTS_INT_EQUAL(tc, 7771, fromport);

Because we weren't randomizing this, we hadn't noted that fromport was
not being filled in by apr_socket_recvfrom() (although the address is).

On Linux, ipv6 loopback enabled;

./testall -v testsockets
testsockets         : |Line 178: expected <7771>, but saw <4242>
FAILED 1 of 6

Should this test be corrected, and is this a bug that should be addressed
in the 1.2.x timeframe?

Bill

Re: Bug to fix or not in 1.2.x - recvfrom?

Posted by Joe Orton <jo...@redhat.com>.
On Mon, Oct 15, 2007 at 01:17:46AM -0500, William Rowe wrote:
> [more details about that universal recvfrom issue in my prior note, I 
> thought
> I had sent this hours ago...]
> 
>     apr_sockaddr_ip_get(&ip_addr, from);
>     fromport = from->port;
>     ABTS_STR_EQUAL(tc, addr, ip_addr);
>     ABTS_INT_EQUAL(tc, 7771, fromport);
> 
> Because we weren't randomizing this, we hadn't noted that fromport was
> not being filled in by apr_socket_recvfrom() (although the address is).
> 
> On Linux, ipv6 loopback enabled;
> 
> ./testall -v testsockets
> testsockets         : |Line 178: expected <7771>, but saw <4242>
> FAILED 1 of 6

Well, yes, you merged a test case without the corresponding bug fix that 
it was testing for (both were part of r467600).

If you revert the changes you made to testsockets.c, and backport 
r467600 in its entirety, I don't see any problems here on Linux.

joe