aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Fitzsimmons2016-03-16 09:15:17 -0400
committerThomas Fitzsimmons2016-03-16 09:35:59 -0400
commitc3ed95b1c57265138b7673ea37eef2d30204abcc (patch)
tree10e90d5a7a2e6d1a1ac56eff949f87c0ed1b40b6
parent2036be4666becf02f4524d63595e3da55b14ff0d (diff)
downloademacs-c3ed95b1c57265138b7673ea37eef2d30204abcc.tar.gz
emacs-c3ed95b1c57265138b7673ea37eef2d30204abcc.zip
Move xsd:base64Binary decoding fix to debbugs.el 0.9.1
* lisp/net/soap-client.el (soap-encode-xs-basic-type): Do not assume xsd:base64Binary values are UTF-8 strings. (soap-decode-xs-basic-type): Likewise. (soap-invoke): Document xsd:base64Binary handling.
-rw-r--r--lisp/net/soap-client.el10
1 files changed, 7 insertions, 3 deletions
diff --git a/lisp/net/soap-client.el b/lisp/net/soap-client.el
index 74024644966..12c9f419555 100644
--- a/lisp/net/soap-client.el
+++ b/lisp/net/soap-client.el
@@ -538,7 +538,7 @@ This is a specialization of `soap-encode-value' for
538 (base64Binary 538 (base64Binary
539 (unless (stringp value) 539 (unless (stringp value)
540 (error "Not a string value for base64Binary")) 540 (error "Not a string value for base64Binary"))
541 (base64-encode-string (encode-coding-string value 'utf-8))) 541 (base64-encode-string value))
542 542
543 (otherwise 543 (otherwise
544 (error "Don't know how to encode %s for type %s" 544 (error "Don't know how to encode %s for type %s"
@@ -682,7 +682,7 @@ This is a specialization of `soap-decode-type' for
682 decimal byte float double duration) 682 decimal byte float double duration)
683 (string-to-number (car contents))) 683 (string-to-number (car contents)))
684 (boolean (string= (downcase (car contents)) "true")) 684 (boolean (string= (downcase (car contents)) "true"))
685 (base64Binary (decode-coding-string (base64-decode-string (car contents)) 'utf-8)) 685 (base64Binary (base64-decode-string (car contents)))
686 (anyType (soap-decode-any-type node)) 686 (anyType (soap-decode-any-type node))
687 (Array (soap-decode-array node)))))) 687 (Array (soap-decode-array node))))))
688 688
@@ -3096,7 +3096,11 @@ the SOAP request.
3096NOTE: The SOAP service provider should document the available 3096NOTE: The SOAP service provider should document the available
3097operations and their parameters for the service. You can also 3097operations and their parameters for the service. You can also
3098use the `soap-inspect' function to browse the available 3098use the `soap-inspect' function to browse the available
3099operations in a WSDL document." 3099operations in a WSDL document.
3100
3101NOTE: `soap-invoke' base64-decodes xsd:base64Binary return values
3102into unibyte strings; these byte-strings require further
3103interpretation by the caller."
3100 (apply #'soap-invoke-internal nil nil wsdl service operation-name parameters)) 3104 (apply #'soap-invoke-internal nil nil wsdl service operation-name parameters))
3101 3105
3102(defun soap-invoke-async (callback cbargs wsdl service operation-name 3106(defun soap-invoke-async (callback cbargs wsdl service operation-name