mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-02-26 15:05:46 +08:00
ThreadStartEvent.java (Event): Event type is "THREAD_START" not "THREAD_END".
* gnu/classpath/jdwp/event/ThreadStartEvent.java (Event): Event type is "THREAD_START" not "THREAD_END". * gnu/classpath/jdwp/transport/SocketTransport.java (ITransport): Handle configure strings ":port" and "port". From-SVN: r123436
This commit is contained in:
parent
c3b7031d96
commit
60e656f58b
@ -1,3 +1,11 @@
|
||||
2007-04-02 Keith Seitz <keiths@redhat.com>
|
||||
|
||||
* gnu/classpath/jdwp/event/ThreadStartEvent.java (Event):
|
||||
Event type is "THREAD_START" not "THREAD_END".
|
||||
|
||||
* gnu/classpath/jdwp/transport/SocketTransport.java (ITransport):
|
||||
Handle configure strings ":port" and "port".
|
||||
|
||||
2007-03-30 Andrew Haley <aph@redhat.com>
|
||||
|
||||
* javax/management/ObjectName.java: Handle 0-length names.
|
||||
|
@ -1,6 +1,6 @@
|
||||
/* ThreadStartEvent.java -- An event specifying that a new thread
|
||||
has started in the virtual machine
|
||||
Copyright (C) 2005 Free Software Foundation
|
||||
Copyright (C) 2005, 2007 Free Software Foundation
|
||||
|
||||
This file is part of GNU Classpath.
|
||||
|
||||
@ -75,7 +75,7 @@ public class ThreadStartEvent
|
||||
* @param thread the thread ID in which event occurred
|
||||
*/
|
||||
public ThreadStartEvent (Thread thread) {
|
||||
super (JdwpConstants.EventKind.THREAD_END);
|
||||
super (JdwpConstants.EventKind.THREAD_START);
|
||||
_thread = thread;
|
||||
}
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
/* SocketTransport.java -- a socket transport
|
||||
Copyright (C) 2005 Free Software Foundation
|
||||
Copyright (C) 2005, 2007 Free Software Foundation
|
||||
|
||||
This file is part of GNU Classpath.
|
||||
|
||||
@ -89,27 +89,36 @@ class SocketTransport
|
||||
* @param properties the properties of the JDWP session
|
||||
* @throws TransportException for any configury errors
|
||||
*/
|
||||
public void configure (HashMap properties)
|
||||
public void configure(HashMap properties)
|
||||
throws TransportException
|
||||
{
|
||||
// Get address [form: "hostname:port"]
|
||||
String p = (String) properties.get (_PROPERTY_ADDRESS);
|
||||
// Get server [form: "y" or "n"]
|
||||
String p = (String) properties.get(_PROPERTY_SERVER);
|
||||
if (p != null)
|
||||
{
|
||||
String[] s = p.split (":");
|
||||
if (s.length == 2)
|
||||
{
|
||||
_host = s[0];
|
||||
_port = Integer.parseInt (s[1]);
|
||||
}
|
||||
if (p.toLowerCase().equals("y"))
|
||||
_server = true;
|
||||
}
|
||||
|
||||
// Get server [form: "y" or "n"]
|
||||
p = (String) properties.get (_PROPERTY_SERVER);
|
||||
// Get address [form: "hostname:port"]
|
||||
p = (String) properties.get(_PROPERTY_ADDRESS);
|
||||
if (p != null)
|
||||
{
|
||||
if (p.toLowerCase().equals ("y"))
|
||||
_server = true;
|
||||
String[] s = p.split(":");
|
||||
if (s.length == 1)
|
||||
{
|
||||
// Port number only. Assume "localhost"
|
||||
_port = Integer.parseInt(s[0]);
|
||||
_host = "localhost";
|
||||
}
|
||||
else
|
||||
{
|
||||
if (s[0].length() == 0)
|
||||
_host = "localhost";
|
||||
else
|
||||
_host = s[0];
|
||||
_port = Integer.parseInt(s[1]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user