cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r683261 - /cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/interceptor/JAXRSOutInterceptor.java
Date Wed, 06 Aug 2008 13:38:13 GMT
Author: dkulp
Date: Wed Aug  6 06:38:10 2008
New Revision: 683261

URL: http://svn.apache.org/viewvc?rev=683261&view=rev
Log:
[CXF-1730] Add a NPE guard.   It DOESN'T look like this should be needed though as the JAXRSInInterceptor
should have 
always set this.


Modified:
    cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/interceptor/JAXRSOutInterceptor.java

Modified: cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/interceptor/JAXRSOutInterceptor.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/interceptor/JAXRSOutInterceptor.java?rev=683261&r1=683260&r2=683261&view=diff
==============================================================================
--- cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/interceptor/JAXRSOutInterceptor.java
(original)
+++ cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/interceptor/JAXRSOutInterceptor.java
Wed Aug  6 06:38:10 2008
@@ -196,7 +196,9 @@
         }
         List<MediaType> acceptContentTypes = 
             (List<MediaType>)exchange.get(Message.ACCEPT_CONTENT_TYPE);
-        
+        if (acceptContentTypes == null) {
+            acceptContentTypes = JAXRSUtils.sortMediaTypes("*/*");
+        }        
         return JAXRSUtils.intersectMimeTypes(acceptContentTypes, produceTypes);
         
     }



Mime
View raw message