geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ga...@apache.org
Subject svn commit: r563974 - /geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/soap/TradeWebSoapProxy.java
Date Wed, 08 Aug 2007 18:43:45 GMT
Author: gawor
Date: Wed Aug  8 11:43:42 2007
New Revision: 563974

URL: http://svn.apache.org/viewvc?view=rev&rev=563974
Log:
check for null

Modified:
    geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/soap/TradeWebSoapProxy.java

Modified: geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/soap/TradeWebSoapProxy.java
URL: http://svn.apache.org/viewvc/geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/soap/TradeWebSoapProxy.java?view=diff&rev=563974&r1=563973&r2=563974
==============================================================================
--- geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/soap/TradeWebSoapProxy.java
(original)
+++ geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/soap/TradeWebSoapProxy.java
Wed Aug  8 11:43:42 2007
@@ -164,7 +164,7 @@
 	public Collection getHoldings(String userID) throws Exception, RemoteException {
 		Object[] holdings = getTrade().getHoldings(userID);
 		ArrayList holdingsRet = new ArrayList();
-		if (holdings.length == 0) {
+		if (holdings == null || holdings.length == 0) {
 			return holdingsRet;
 		}
 		
@@ -187,7 +187,7 @@
 	public Collection getOrders(String userID) throws Exception, RemoteException {
 		Object[] orders = getTrade().getOrders(userID);
 		ArrayList ordersRet = new ArrayList();
-		if (orders.length == 0) {
+		if (orders == null || orders.length == 0) {
 			return ordersRet;
 		}
 		for (int ii = 0; ii < orders.length; ii++) {
@@ -293,7 +293,7 @@
 
 	private Collection convertQuoteDataBeanWSArrayToCollectionBase(Object[] quotes) {	
 		ArrayList quotesRet = new ArrayList();
-		if (quotes.length == 0) {
+		if (quotes == null || quotes.length == 0) {
 			return quotesRet;
 		}
 		for (int ii = 0; ii < quotes.length; ii++) {



Mime
View raw message