1.1 --- a/src/share/jaxws_classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/SOAPMessageFactory1_1Impl.java Thu Apr 04 19:05:24 2013 -0700 1.2 +++ b/src/share/jaxws_classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/SOAPMessageFactory1_1Impl.java Tue Apr 09 14:51:13 2013 +0100 1.3 @@ -1,5 +1,5 @@ 1.4 /* 1.5 - * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. 1.6 + * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. 1.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 1.8 * 1.9 * This code is free software; you can redistribute it and/or modify it 1.10 @@ -50,12 +50,16 @@ 1.11 return new Message1_1Impl(isFastInfoset, acceptFastInfoset); 1.12 } 1.13 1.14 - public SOAPMessage createMessage(MimeHeaders headers, InputStream in) 1.15 - throws IOException, SOAPExceptionImpl { 1.16 - if ((headers == null) || (getContentType(headers) == null)) { 1.17 + public SOAPMessage createMessage(MimeHeaders headers, InputStream in) throws IOException, SOAPExceptionImpl { 1.18 + 1.19 + if (headers == null) { 1.20 headers = new MimeHeaders(); 1.21 + } 1.22 + 1.23 + if (getContentType(headers) == null) { 1.24 headers.setHeader("Content-Type", SOAPConstants.SOAP_1_1_CONTENT_TYPE); 1.25 } 1.26 + 1.27 MessageImpl msg = new Message1_1Impl(headers, in); 1.28 msg.setLazyAttachments(lazyAttachments); 1.29 return msg;