/[classpath]/classpath/java/net/NetworkInterface.java
ViewVC logotype

Diff of /classpath/java/net/NetworkInterface.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.5 by arenn, Sun May 25 18:03:51 2003 UTC revision 1.6 by mkoch, Thu Oct 2 18:49:59 2003 UTC
# Line 37  exception statement from your version. * Line 37  exception statement from your version. *
37    
38  package java.net;  package java.net;
39    
40    import gnu.classpath.Configuration;
41  import java.util.Enumeration;  import java.util.Enumeration;
42  import java.util.Vector;  import java.util.Vector;
43    
# Line 52  import java.util.Vector; Line 53  import java.util.Vector;
53   */   */
54  public final class NetworkInterface  public final class NetworkInterface
55  {  {
56      static
57      {
58        if (Configuration.INIT_LOAD_LIBRARY)
59          {
60            System.loadLibrary ("javanet");
61          }
62      }
63    
64    private String name;    private String name;
65        
66    private Vector inetAddresses;    private Vector inetAddresses;
# Line 185  public final class NetworkInterface Line 194  public final class NetworkInterface
194    public static Enumeration getNetworkInterfaces ()    public static Enumeration getNetworkInterfaces ()
195      throws SocketException      throws SocketException
196    {    {
197      Vector networkInterfaces = getRealNetworkInterfaces ();      Vector networkInterfaces = getRealNetworkInterfaces();
   
     Enumeration tmp = networkInterfaces.elements ();  
198    
199      if (tmp.hasMoreElements ())      if (networkInterfaces.isEmpty())
200        return tmp;        return null;
201    
202      return null;      return networkInterfaces.elements();
203    }    }
204    
205    /**    /**

Legend:
Removed from v.1.5  
changed lines
  Added in v.1.6

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26