src/share/classes/javax/management/remote/JMXServiceURL.java

Print this page

        

*** 1,7 **** /* ! * Copyright (c) 2002, 2010, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this --- 1,7 ---- /* ! * Copyright (c) 2002, 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this
*** 342,352 **** private static final String INVALID_INSTANCE_MSG = "Trying to deserialize an invalid instance of JMXServiceURL"; private void readObject(ObjectInputStream inputStream) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gf = inputStream.readFields(); String h = (String)gf.get("host", null); ! int p = (int)gf.get("port", -1); String proto = (String)gf.get("protocol", null); String url = (String)gf.get("urlPath", null); if (proto == null || url == null || h == null) { StringBuilder sb = new StringBuilder(INVALID_INSTANCE_MSG).append('['); --- 342,352 ---- private static final String INVALID_INSTANCE_MSG = "Trying to deserialize an invalid instance of JMXServiceURL"; private void readObject(ObjectInputStream inputStream) throws IOException, ClassNotFoundException { ObjectInputStream.GetField gf = inputStream.readFields(); String h = (String)gf.get("host", null); ! int p = gf.get("port", -1); String proto = (String)gf.get("protocol", null); String url = (String)gf.get("urlPath", null); if (proto == null || url == null || h == null) { StringBuilder sb = new StringBuilder(INVALID_INSTANCE_MSG).append('[');