Commit f4e1433a by Mark Wielaard

[multiple changes]

2005-11-17  Mark Wielaard  <mark@klomp.org>

       * gnu/java/net/protocol/file/Handler.java: Removed, fully merged now.
       * java/net/ServerSocket.java: Likewise.
       * sources.am: Regenerated.
       * Makefile.in: Regenerated.

2005-11-17  Mark Wielaard  <mark@klomp.org>

       Fixes bug #24006
       * java/net/ServerSocket.java (implAccept): Set Socket.bound to true.

2005-11-17  Tom Tromey  <tromey@redhat.com>

       * java/net/ServerSocket.java (accept): Use correct security manager
       call.

2005-11-17  Jeroen Frijters  <jeroen@frijters.net>

       * java/net/ServerSocket.java
       (bound): Removed.
       (local): New field.
       (bind): Cache local socket address.
       (getInetAddress, getLocalPort, getLocalSocketAddress, isBound):
       Use cached local socket address.
       (close): bound field was removed.

2005-11-17  Tom Tromey  <tromey@redhat.com>

       * java/net/URLConnection.java (setDoInput): Javadoc fix.
       (setDoOutput): Likewise.
       (setContentHandlerFactory): Likewise.
       (setFileNameMap): Likewise.

2005-11-17  Mark Wielaard  <mark@klomp.org>

       * java/net/URLClassloader.java (addURLs): Add comment about jboss.

2005-11-17  Mark Wielaard  <mark@klomp.org>

       * java/net/URLClassLoader.java (addURLs): Don't call addURL(), but
       call urls.add() and addURLImpl() directly on each URL.

2005-11-17  Tom Tromey  <tromey@redhat.com>

       * java/net/URLClassLoader.java (definePackage): Javadoc fixes.

2005-11-17  Jeroen Frijters  <jeroen@frijters.net>

       * java/net/URLClassLoader.java
       (Resource.name): Removed field.
       (JarURLResource.name): Added field.
       (FileResource.getURL): Use File.toURL() instead of doing it in
       a way that breaks on Windows.

2005-11-17  Roman Kennke  <roman@kennke.org>

       Reported by: Ingo Proetel  <proetel@aicas.com>
       * java/net/URLClassLoader.java
       (findClass): Added null check to avoid NullPointerException.

2005-11-17  David Gilbert  <david.gilbert@object-refinery.com>

       * java/net/URLClassLoader.java: reordered some API doc comments to
       suppress Eclipse warnings, and fixed API doc link.

2005-11-17  Tom Tromey  <tromey@redhat.com>

       * java/net/URLClassLoader.java (URLClassLoader): Removed
       unused constructor.

2005-11-17  Jeroen Frijters  <jeroen@frijters.net>

       * java/net/URLClassLoader (findClass): Close InputStream after we're
       done with it.

From-SVN: r107133
parent 11922361
2005-11-17 Mark Wielaard <mark@klomp.org>
* gnu/java/net/protocol/file/Handler.java: Removed, fully merged now.
* java/net/ServerSocket.java: Likewise.
* sources.am: Regenerated.
* Makefile.in: Regenerated.
2005-11-17 Mark Wielaard <mark@klomp.org>
Fixes bug #24006
* java/net/ServerSocket.java (implAccept): Set Socket.bound to true.
2005-11-17 Tom Tromey <tromey@redhat.com>
* java/net/ServerSocket.java (accept): Use correct security manager
call.
2005-11-17 Jeroen Frijters <jeroen@frijters.net>
* java/net/ServerSocket.java
(bound): Removed.
(local): New field.
(bind): Cache local socket address.
(getInetAddress, getLocalPort, getLocalSocketAddress, isBound):
Use cached local socket address.
(close): bound field was removed.
2005-11-17 Tom Tromey <tromey@redhat.com>
* java/net/URLConnection.java (setDoInput): Javadoc fix.
(setDoOutput): Likewise.
(setContentHandlerFactory): Likewise.
(setFileNameMap): Likewise.
2005-11-17 Mark Wielaard <mark@klomp.org>
* java/net/URLClassloader.java (addURLs): Add comment about jboss.
2005-11-17 Mark Wielaard <mark@klomp.org>
* java/net/URLClassLoader.java (addURLs): Don't call addURL(), but
call urls.add() and addURLImpl() directly on each URL.
2005-11-17 Tom Tromey <tromey@redhat.com>
* java/net/URLClassLoader.java (definePackage): Javadoc fixes.
2005-11-17 Jeroen Frijters <jeroen@frijters.net>
* java/net/URLClassLoader.java
(Resource.name): Removed field.
(JarURLResource.name): Added field.
(FileResource.getURL): Use File.toURL() instead of doing it in
a way that breaks on Windows.
2005-11-17 Roman Kennke <roman@kennke.org>
Reported by: Ingo Proetel <proetel@aicas.com>
* java/net/URLClassLoader.java
(findClass): Added null check to avoid NullPointerException.
2005-11-17 David Gilbert <david.gilbert@object-refinery.com>
* java/net/URLClassLoader.java: reordered some API doc comments to
suppress Eclipse warnings, and fixed API doc link.
2005-11-17 Tom Tromey <tromey@redhat.com>
* java/net/URLClassLoader.java (URLClassLoader): Removed
unused constructor.
2005-11-17 Jeroen Frijters <jeroen@frijters.net>
* java/net/URLClassLoader (findClass): Close InputStream after we're
done with it.
2005-11-17 Bryce McKinlay <mckinlay@redhat.com> 2005-11-17 Bryce McKinlay <mckinlay@redhat.com>
Implement -Xss. Implement -Xss.
......
...@@ -1426,9 +1426,9 @@ gnu/java/net/protocol/gcjlib/Handler.java ...@@ -1426,9 +1426,9 @@ gnu/java/net/protocol/gcjlib/Handler.java
gnu_java_net_header_files = $(patsubst classpath/%,%,$(patsubst %.java,%.h,$(gnu_java_net_source_files))) gnu_java_net_header_files = $(patsubst classpath/%,%,$(patsubst %.java,%.h,$(gnu_java_net_source_files)))
gnu_java_net_protocol_file_source_files = \ gnu_java_net_protocol_file_source_files = \
gnu/java/net/protocol/file/Connection.java \ gnu/java/net/protocol/file/Connection.java \
gnu/java/net/protocol/file/Handler.java classpath/gnu/java/net/protocol/file/Handler.java
gnu_java_net_protocol_file_header_files = $(patsubst %.java,%.h,$(gnu_java_net_protocol_file_source_files)) gnu_java_net_protocol_file_header_files = $(patsubst classpath/%,%,$(patsubst %.java,%.h,$(gnu_java_net_protocol_file_source_files)))
gnu_java_net_protocol_ftp_source_files = \ gnu_java_net_protocol_ftp_source_files = \
classpath/gnu/java/net/protocol/ftp/ActiveModeDTP.java \ classpath/gnu/java/net/protocol/ftp/ActiveModeDTP.java \
classpath/gnu/java/net/protocol/ftp/BlockInputStream.java \ classpath/gnu/java/net/protocol/ftp/BlockInputStream.java \
...@@ -2801,7 +2801,7 @@ classpath/java/net/NoRouteToHostException.java \ ...@@ -2801,7 +2801,7 @@ classpath/java/net/NoRouteToHostException.java \
classpath/java/net/PasswordAuthentication.java \ classpath/java/net/PasswordAuthentication.java \
classpath/java/net/PortUnreachableException.java \ classpath/java/net/PortUnreachableException.java \
classpath/java/net/ProtocolException.java \ classpath/java/net/ProtocolException.java \
java/net/ServerSocket.java \ classpath/java/net/ServerSocket.java \
classpath/java/net/Socket.java \ classpath/java/net/Socket.java \
classpath/java/net/SocketAddress.java \ classpath/java/net/SocketAddress.java \
classpath/java/net/SocketException.java \ classpath/java/net/SocketException.java \
......
/* Handler.java -- "file" protocol handler for java.net
Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004 Free Software Foundation, Inc.
This file is part of GNU Classpath.
GNU Classpath is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Classpath is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Classpath; see the file COPYING. If not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301 USA.
Linking this library statically or dynamically with other modules is
making a combined work based on this library. Thus, the terms and
conditions of the GNU General Public License cover the whole
combination.
As a special exception, the copyright holders of this library give you
permission to link this library with independent modules to produce an
executable, regardless of the license terms of these independent
modules, and to copy and distribute the resulting executable under
terms of your choice, provided that you also meet, for each linked
independent module, the terms and conditions of the license of that
module. An independent module is a module which is not derived from
or based on this library. If you modify this library, you may extend
this exception to your version of the library, but you are not
obligated to do so. If you do not wish to do so, delete this
exception statement from your version. */
package gnu.java.net.protocol.file;
import java.io.IOException;
import java.net.URL;
import java.net.URLConnection;
import java.net.URLStreamHandler;
/**
* This is the protocol handler for the "file" protocol.
* It implements the abstract openConnection() method from
* URLStreamHandler by returning a new FileURLConnection object (from
* this package). All other methods are inherited
*
* @author Aaron M. Renn (arenn@urbanophile.com)
* @author Warren Levy (warrenl@cygnus.com)
*/
public class Handler extends URLStreamHandler
{
/**
* A do nothing constructor
*/
public Handler()
{
}
/**
* This method returs a new FileURLConnection for the specified URL
*
* @param url The URL to return a connection for
*
* @return The URLConnection
*
* @exception IOException If an error occurs
*/
protected URLConnection openConnection(URL url) throws IOException
{
// If a hostname is set, then we need to switch protocols to ftp
// in order to transfer this from the remote host.
String host = url.getHost();
if ((host != null) && (! host.equals("")))
{
// Reset the protocol (and implicitly the handler) for this URL.
// Then have the URL attempt the connection again, as it will
// get the changed handler the next time around.
// If the ftp protocol handler is not installed, an
// exception will be thrown from the new openConnection() call.
setURL (url, "ftp", url.getHost(), url.getPort(), url.getFile(),
url.getRef());
return url.openConnection();
}
return new Connection(url);
}
} // class Handler
...@@ -248,12 +248,10 @@ public class URLClassLoader extends SecureClassLoader ...@@ -248,12 +248,10 @@ public class URLClassLoader extends SecureClassLoader
abstract static class Resource abstract static class Resource
{ {
final URLLoader loader; final URLLoader loader;
final String name;
Resource(URLLoader loader, String name) Resource(URLLoader loader)
{ {
this.loader = loader; this.loader = loader;
this.name = name;
} }
/** /**
...@@ -404,11 +402,13 @@ public class URLClassLoader extends SecureClassLoader ...@@ -404,11 +402,13 @@ public class URLClassLoader extends SecureClassLoader
static final class JarURLResource extends Resource static final class JarURLResource extends Resource
{ {
private final JarEntry entry; private final JarEntry entry;
private final String name;
JarURLResource(JarURLLoader loader, String name, JarEntry entry) JarURLResource(JarURLLoader loader, String name, JarEntry entry)
{ {
super(loader, name); super(loader);
this.entry = entry; this.entry = entry;
this.name = name;
} }
InputStream getInputStream() throws IOException InputStream getInputStream() throws IOException
...@@ -509,7 +509,7 @@ public class URLClassLoader extends SecureClassLoader ...@@ -509,7 +509,7 @@ public class URLClassLoader extends SecureClassLoader
RemoteResource(RemoteURLLoader loader, String name, URL url, RemoteResource(RemoteURLLoader loader, String name, URL url,
InputStream stream, int length) InputStream stream, int length)
{ {
super(loader, name); super(loader);
this.url = url; this.url = url;
this.stream = stream; this.stream = stream;
this.length = length; this.length = length;
...@@ -561,15 +561,15 @@ public class URLClassLoader extends SecureClassLoader ...@@ -561,15 +561,15 @@ public class URLClassLoader extends SecureClassLoader
URL url = helper.findResource(name); URL url = helper.findResource(name);
if (url == null) if (url == null)
return null; return null;
return new SoResource(this, name, url); return new SoResource(this, url);
} }
} }
final static class SoResource extends Resource final static class SoResource extends Resource
{ {
SoResource(SoURLLoader loader, String name, URL url) SoResource(SoURLLoader loader, URL url)
{ {
super(loader, name); super(loader);
this.url = url; this.url = url;
} }
...@@ -614,7 +614,7 @@ public class URLClassLoader extends SecureClassLoader ...@@ -614,7 +614,7 @@ public class URLClassLoader extends SecureClassLoader
{ {
File file = new File(dir, name).getCanonicalFile(); File file = new File(dir, name).getCanonicalFile();
if (file.exists() && !file.isDirectory()) if (file.exists() && !file.isDirectory())
return new FileResource(this, file.getPath(), file); return new FileResource(this, file);
} }
catch (IOException e) catch (IOException e)
{ {
...@@ -628,9 +628,9 @@ public class URLClassLoader extends SecureClassLoader ...@@ -628,9 +628,9 @@ public class URLClassLoader extends SecureClassLoader
{ {
final File file; final File file;
FileResource(FileURLLoader loader, String name, File file) FileResource(FileURLLoader loader, File file)
{ {
super(loader, name); super(loader);
this.file = file; this.file = file;
} }
...@@ -673,8 +673,7 @@ public class URLClassLoader extends SecureClassLoader ...@@ -673,8 +673,7 @@ public class URLClassLoader extends SecureClassLoader
{ {
try try
{ {
return new URL(loader.baseURL, name, return file.toURL();
loader.classloader.getURLStreamHandler("file"));
} }
catch (MalformedURLException e) catch (MalformedURLException e)
{ {
...@@ -711,12 +710,14 @@ public class URLClassLoader extends SecureClassLoader ...@@ -711,12 +710,14 @@ public class URLClassLoader extends SecureClassLoader
static final class CoreResource extends Resource static final class CoreResource extends Resource
{ {
final Core core; private final Core core;
private final String name;
CoreResource(CoreURLLoader loader, String name, Core core) CoreResource(CoreURLLoader loader, String name, Core core)
{ {
super(loader, name); super(loader);
this.core = core; this.core = core;
this.name = name;
} }
InputStream getInputStream() throws IOException InputStream getInputStream() throws IOException
...@@ -755,10 +756,10 @@ public class URLClassLoader extends SecureClassLoader ...@@ -755,10 +756,10 @@ public class URLClassLoader extends SecureClassLoader
* in the order given to the URLClassLoader which uses these URLs to * in the order given to the URLClassLoader which uses these URLs to
* load classes and resources (after using the default parent ClassLoader). * load classes and resources (after using the default parent ClassLoader).
* *
* @exception SecurityException if the SecurityManager disallows the
* creation of a ClassLoader.
* @param urls Locations that should be searched by this ClassLoader when * @param urls Locations that should be searched by this ClassLoader when
* resolving Classes or Resources. * resolving Classes or Resources.
* @exception SecurityException if the SecurityManager disallows the
* creation of a ClassLoader.
* @see SecureClassLoader * @see SecureClassLoader
*/ */
public URLClassLoader(URL[] urls) throws SecurityException public URLClassLoader(URL[] urls) throws SecurityException
...@@ -770,25 +771,6 @@ public class URLClassLoader extends SecureClassLoader ...@@ -770,25 +771,6 @@ public class URLClassLoader extends SecureClassLoader
} }
/** /**
* Private constructor used by the static
* <code>newInstance(URL[])</code> method. Creates an
* <code>URLClassLoader</code> without any <code>URL</code>s
* yet. This is used to bypass the normal security check for
* creating classloaders, but remembers the security context which
* will be used when defining classes. The <code>URL</code>s to
* load from must be added by the <code>newInstance()</code> method
* in the security context of the caller.
*
* @param securityContext the security context of the unprivileged code.
*/
private URLClassLoader(AccessControlContext securityContext)
{
super();
this.factory = null;
this.securityContext = securityContext;
}
/**
* Creates a <code>URLClassLoader</code> that gets classes from the supplied * Creates a <code>URLClassLoader</code> that gets classes from the supplied
* <code>URL</code>s. * <code>URL</code>s.
* To determine if this classloader may be created the constructor of * To determine if this classloader may be created the constructor of
...@@ -796,13 +778,13 @@ public class URLClassLoader extends SecureClassLoader ...@@ -796,13 +778,13 @@ public class URLClassLoader extends SecureClassLoader
* can throw a SecurityException. Then the supplied URLs are added * can throw a SecurityException. Then the supplied URLs are added
* in the order given to the URLClassLoader which uses these URLs to * in the order given to the URLClassLoader which uses these URLs to
* load classes and resources (after using the supplied parent ClassLoader). * load classes and resources (after using the supplied parent ClassLoader).
* @exception SecurityException if the SecurityManager disallows the
* creation of a ClassLoader.
* @exception SecurityException
* @param urls Locations that should be searched by this ClassLoader when * @param urls Locations that should be searched by this ClassLoader when
* resolving Classes or Resources. * resolving Classes or Resources.
* @param parent The parent class loader used before trying this class * @param parent The parent class loader used before trying this class
* loader. * loader.
* @exception SecurityException if the SecurityManager disallows the
* creation of a ClassLoader.
* @exception SecurityException
* @see SecureClassLoader * @see SecureClassLoader
*/ */
public URLClassLoader(URL[] urls, ClassLoader parent) public URLClassLoader(URL[] urls, ClassLoader parent)
...@@ -844,14 +826,14 @@ public class URLClassLoader extends SecureClassLoader ...@@ -844,14 +826,14 @@ public class URLClassLoader extends SecureClassLoader
* load classes and resources (after using the supplied parent ClassLoader). * load classes and resources (after using the supplied parent ClassLoader).
* It will use the supplied <CODE>URLStreamHandlerFactory</CODE> to get the * It will use the supplied <CODE>URLStreamHandlerFactory</CODE> to get the
* protocol handlers of the supplied URLs. * protocol handlers of the supplied URLs.
* @exception SecurityException if the SecurityManager disallows the
* creation of a ClassLoader.
* @exception SecurityException
* @param urls Locations that should be searched by this ClassLoader when * @param urls Locations that should be searched by this ClassLoader when
* resolving Classes or Resources. * resolving Classes or Resources.
* @param parent The parent class loader used before trying this class * @param parent The parent class loader used before trying this class
* loader. * loader.
* @param factory Used to get the protocol handler for the URLs. * @param factory Used to get the protocol handler for the URLs.
* @exception SecurityException if the SecurityManager disallows the
* creation of a ClassLoader.
* @exception SecurityException
* @see SecureClassLoader * @see SecureClassLoader
*/ */
public URLClassLoader(URL[] urls, ClassLoader parent, public URLClassLoader(URL[] urls, ClassLoader parent,
...@@ -938,13 +920,21 @@ public class URLClassLoader extends SecureClassLoader ...@@ -938,13 +920,21 @@ public class URLClassLoader extends SecureClassLoader
} }
/** /**
* Adds an array of new locations to the end of the internal URL store. * Adds an array of new locations to the end of the internal URL
* store. Called from the the constructors. Should not call to the
* protected addURL() method since that can be overridden and
* subclasses are not yet in a good state at this point.
* jboss 4.0.3 for example depends on this.
*
* @param newUrls the locations to add * @param newUrls the locations to add
*/ */
private void addURLs(URL[] newUrls) private void addURLs(URL[] newUrls)
{ {
for (int i = 0; i < newUrls.length; i++) for (int i = 0; i < newUrls.length; i++)
addURL(newUrls[i]); {
urls.add(newUrls[i]);
addURLImpl(newUrls[i]);
}
} }
/** /**
...@@ -969,13 +959,13 @@ public class URLClassLoader extends SecureClassLoader ...@@ -969,13 +959,13 @@ public class URLClassLoader extends SecureClassLoader
* package is sealed. If the Manifest indicates that the package is sealed * package is sealed. If the Manifest indicates that the package is sealed
* then the Package will be sealed with respect to the supplied URL. * then the Package will be sealed with respect to the supplied URL.
* *
* @exception IllegalArgumentException If this package name already exists
* in this class loader
* @param name The name of the package * @param name The name of the package
* @param manifest The manifest describing the specification, * @param manifest The manifest describing the specification,
* implementation and sealing details of the package * implementation and sealing details of the package
* @param url the code source url to seal the package * @param url the code source url to seal the package
* @return the defined Package * @return the defined Package
* @throws IllegalArgumentException If this package name already exists
* in this class loader
*/ */
protected Package definePackage(String name, Manifest manifest, URL url) protected Package definePackage(String name, Manifest manifest, URL url)
throws IllegalArgumentException throws IllegalArgumentException
...@@ -1064,6 +1054,8 @@ public class URLClassLoader extends SecureClassLoader ...@@ -1064,6 +1054,8 @@ public class URLClassLoader extends SecureClassLoader
{ {
byte[] data; byte[] data;
InputStream in = resource.getInputStream(); InputStream in = resource.getInputStream();
try
{
int length = resource.getLength(); int length = resource.getLength();
if (length != -1) if (length != -1)
{ {
...@@ -1095,6 +1087,11 @@ public class URLClassLoader extends SecureClassLoader ...@@ -1095,6 +1087,11 @@ public class URLClassLoader extends SecureClassLoader
} }
data = out.toByteArray(); data = out.toByteArray();
} }
}
finally
{
in.close();
}
final byte[] classData = data; final byte[] classData = data;
// Now get the CodeSource // Now get the CodeSource
...@@ -1136,7 +1133,11 @@ public class URLClassLoader extends SecureClassLoader ...@@ -1136,7 +1133,11 @@ public class URLClassLoader extends SecureClassLoader
else else
result = defineClass(className, classData, 0, classData.length, source); result = defineClass(className, classData, 0, classData.length, source);
super.setSigners(result, resource.getCertificates()); // Avoid NullPointerExceptions.
Certificate[] resourceCertificates = resource.getCertificates();
if(resourceCertificates != null)
super.setSigners(result, resourceCertificates);
return result; return result;
} }
catch (IOException ioe) catch (IOException ioe)
...@@ -1252,11 +1253,11 @@ public class URLClassLoader extends SecureClassLoader ...@@ -1252,11 +1253,11 @@ public class URLClassLoader extends SecureClassLoader
/** /**
* Finds all the resources with a particular name from all the locations. * Finds all the resources with a particular name from all the locations.
* *
* @exception IOException when an error occurs accessing one of the
* locations
* @param resourceName the name of the resource to lookup * @param resourceName the name of the resource to lookup
* @return a (possible empty) enumeration of URLs where the resource can be * @return a (possible empty) enumeration of URLs where the resource can be
* found * found
* @exception IOException when an error occurs accessing one of the
* locations
*/ */
public Enumeration findResources(String resourceName) public Enumeration findResources(String resourceName)
throws IOException throws IOException
...@@ -1291,7 +1292,7 @@ public class URLClassLoader extends SecureClassLoader ...@@ -1291,7 +1292,7 @@ public class URLClassLoader extends SecureClassLoader
* *
* @param source The codesource that needs the permissions to be accessed * @param source The codesource that needs the permissions to be accessed
* @return the collection of permissions needed to access the code resource * @return the collection of permissions needed to access the code resource
* @see java.security.SecureClassLoader#getPermissions() * @see java.security.SecureClassLoader#getPermissions(CodeSource)
*/ */
protected PermissionCollection getPermissions(CodeSource source) protected PermissionCollection getPermissions(CodeSource source)
{ {
......
...@@ -539,7 +539,7 @@ public abstract class URLConnection ...@@ -539,7 +539,7 @@ public abstract class URLConnection
} }
/** /**
* Returns the value of a flag indicating whether or not input is going * Sets the value of a flag indicating whether or not input is going
* to be done for this connection. This default to true unless the * to be done for this connection. This default to true unless the
* doOutput flag is set to false, in which case this defaults to false. * doOutput flag is set to false, in which case this defaults to false.
* *
...@@ -569,7 +569,7 @@ public abstract class URLConnection ...@@ -569,7 +569,7 @@ public abstract class URLConnection
} }
/** /**
* Returns a boolean flag indicating whether or not output will be done * Sets a boolean flag indicating whether or not output will be done
* on this connection. The default value is false, so this method can * on this connection. The default value is false, so this method can
* be used to override the default * be used to override the default
* *
...@@ -860,7 +860,7 @@ public abstract class URLConnection ...@@ -860,7 +860,7 @@ public abstract class URLConnection
} }
/** /**
* Set's the ContentHandlerFactory for an application. This can be called * Sets the ContentHandlerFactory for an application. This can be called
* once and only once. If it is called again, then an Error is thrown. * once and only once. If it is called again, then an Error is thrown.
* Unlike for other set factory methods, this one does not do a security * Unlike for other set factory methods, this one does not do a security
* check prior to setting the factory. * check prior to setting the factory.
...@@ -956,7 +956,7 @@ public abstract class URLConnection ...@@ -956,7 +956,7 @@ public abstract class URLConnection
} }
/** /**
* This method set the <code>FileNameMap</code> object being used * This method sets the <code>FileNameMap</code> object being used
* to decode MIME types by file extension. * to decode MIME types by file extension.
* *
* @param map The <code>FileNameMap</code>. * @param map The <code>FileNameMap</code>.
......
...@@ -976,9 +976,9 @@ gnu/java/net.list: $(gnu_java_net_source_files) ...@@ -976,9 +976,9 @@ gnu/java/net.list: $(gnu_java_net_source_files)
gnu_java_net_protocol_file_source_files = \ gnu_java_net_protocol_file_source_files = \
gnu/java/net/protocol/file/Connection.java \ gnu/java/net/protocol/file/Connection.java \
gnu/java/net/protocol/file/Handler.java classpath/gnu/java/net/protocol/file/Handler.java
gnu_java_net_protocol_file_header_files = $(patsubst %.java,%.h,$(gnu_java_net_protocol_file_source_files)) gnu_java_net_protocol_file_header_files = $(patsubst classpath/%,%,$(patsubst %.java,%.h,$(gnu_java_net_protocol_file_source_files)))
gnu/java/net/protocol/file.list: $(gnu_java_net_protocol_file_source_files) gnu/java/net/protocol/file.list: $(gnu_java_net_protocol_file_source_files)
@$(mkinstalldirs) $(dir $@) @$(mkinstalldirs) $(dir $@)
...@@ -3009,7 +3009,7 @@ classpath/java/net/NoRouteToHostException.java \ ...@@ -3009,7 +3009,7 @@ classpath/java/net/NoRouteToHostException.java \
classpath/java/net/PasswordAuthentication.java \ classpath/java/net/PasswordAuthentication.java \
classpath/java/net/PortUnreachableException.java \ classpath/java/net/PortUnreachableException.java \
classpath/java/net/ProtocolException.java \ classpath/java/net/ProtocolException.java \
java/net/ServerSocket.java \ classpath/java/net/ServerSocket.java \
classpath/java/net/Socket.java \ classpath/java/net/Socket.java \
classpath/java/net/SocketAddress.java \ classpath/java/net/SocketAddress.java \
classpath/java/net/SocketException.java \ classpath/java/net/SocketException.java \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment