Download Install Tutorial Docs FAQ Tools WikiLicense Team IRC Planet Involvement Shop Book

Changeset 785

Show
Ignore:
Timestamp:
11/04/05 14:28:55
Author:
lawouach
Message:

Set allow_none to false to disable None support in returned XMLRPC response

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/cherrypy/lib/filter/xmlrpcfilter.py

    r784 r785  
    193193        encoding = cherrypy.config.get('xmlRpcFilter.encoding', 'utf-8') 
    194194 
     195        # See xmlrpclib documentation 
     196        # Python's None value cannot be used in standard XML-RPC; 
     197        # to allow using it via an extension, provide a true value for allow_none. 
    195198        cherrypy.response.body = [xmlrpclib.dumps( 
    196199            (cherrypy.response.body,), 
    197200            methodresponse=1, 
    198201            encoding=encoding, 
    199             allow_none=1)] 
     202            allow_none=0)] 
    200203        cherrypy.response.headerMap['Content-Type'] = 'text/xml' 
    201204        cherrypy.response.headerMap['Content-Length'] = len(cherrypy.response.body[0]) 

Hosted by WebFaction

Log in as guest/cpguest to create tickets