fix for NPE

git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@390411 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Davies 2006-03-31 12:50:18 +00:00
parent d68fe55933
commit 8f02ba6a53
1 changed files with 11 additions and 3 deletions

View File

@ -287,7 +287,15 @@ public class TransportConnector implements Connector {
public String getName(){
if(name==null){
if(server!=null){
if(server.getConnectURI()!=null){
name=server.getConnectURI().toString();
}else{
name = server.getClass() + ":Not started";
}
}else{
name = "NOT_SET";
}
}
return name;
}