You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "George Harley (JIRA)" <ji...@apache.org> on 2006/04/19 18:35:46 UTC

[jira] Commented: (HARMONY-359) Java 5 Enhancement: One new constructor Socket(Proxy p) in class java.net.Socket.

    [ http://issues.apache.org/jira/browse/HARMONY-359?page=comments#action_12375151 ] 

George Harley commented on HARMONY-359:
---------------------------------------

Hi Richard, 

We have a problem here. With the patch in place we get a compile error from the NIO component. In particular, the accept(Socket, SocketChannelImpl) method of org.apache.harmony.nio.internal.ServerSocketChannelImpl includes a call to the no args org.apache.harmony.luni.net.NetUtil.usingSocks() which no longer exists. 

In my own sandbox the usingSocks() call -its on line 253 of ServerSocketChannelImpl.java - can be updated so that it passes in a null argument for the Proxy. 
i.e. 

    if (NetUtil.usingSocks(null)) {
        return super.accept();
    }

With this tweak in place the NIO component builds fine and all of our unit tests pass. Passing in the null value to NetUtil.usingSocks(Proxy) means that the return value *only* depends on the value of the "socksProxyHost" system property (that behaviour required another little change to the NetUtil.usingSocks(Proxy) method - code now checks for null proxy in both of the if tests). Is this the kind of behaviour that you would expect to see in SocketChannelImpl's accept() method ?

I'll wait to hear back from you before progressing with this issue. 

Thanks, 
George





> Java 5 Enhancement: One new constructor Socket(Proxy p) in class java.net.Socket.
> ---------------------------------------------------------------------------------
>
>          Key: HARMONY-359
>          URL: http://issues.apache.org/jira/browse/HARMONY-359
>      Project: Harmony
>         Type: New Feature

>   Components: Classlib
>     Reporter: Richard Liang
>     Assignee: George Harley
>     Priority: Minor
>  Attachments: luni.src.diff
>
> Hello,
> One new constructor method Socket(Proxy p) in class java.net.Socket, but not implemented in Harmony.
> I'll upload a patch both for code and test soon.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira