Relates :
|
8193435 removed some text, which was added later again in a merge: http://hg.openjdk.java.net/jdk/jdk/rev/68c6f57c40d4 --- a/src/java.desktop/share/classes/java/awt/Toolkit.java 2018-04-23 09:28:30.000000000 +0200 +++ b/src/java.desktop/share/classes/java/awt/Toolkit.java 2018-04-18 15:23:49.000000000 +0200 @@ -678,6 +678,11 @@ * If the connection to the specified URL requires * either {@code URLPermission} or {@code SocketPermission}, * then {@code URLPermission} is used for security checks. + * For compatibility with pre-1.2 security managers, if the access + * is denied with {@code FilePermission} or {@code SocketPermission}, + * the method throws the {@code SecurityException} + * if the corresponding 1.1-style SecurityManager.checkXXX method + * also denies permission. * @param url the URL to use in fetching the pixel data. * @return an image which gets its pixel data from * the specified URL. @@ -719,6 +724,11 @@ * If the connection to the specified URL requires * either {@code URLPermission} or {@code SocketPermission}, * then {@code URLPermission} is used for security checks. + * For compatibility with pre-1.2 security managers, if the access + * is denied with {@code FilePermission} or {@code SocketPermission}, + * the method throws {@code SecurityException} + * if the corresponding 1.1-style SecurityManager.checkXXX method + * also denies permission. * @param url the URL to use in fetching the pixel data. * @return an image which gets its pixel data from * the specified URL.