CloneSet728


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
9220.979statement_sequence[2]
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
192513
libraries/phpxmlrpc/xmlrpc.php
211914
libraries/phpxmlrpc/xmlrpcs.php
Clone Instance
1
Line Count
9
Source Line
2513
Source File
libraries/phpxmlrpc/xmlrpc.php

                        // if response charset encoding is not known / supported, try to use
                        // the default encoding and parse the xml anyway, but log a warning...
                        if (!in_array($resp_encoding, array( 'UTF-8', 'ISO-8859-1', 'US-ASCII'
                                                           )))
                        // the following code might be better for mb_string enabled installs, but
                        // makes the lib about 200% slower...
                        //if (!is_valid_charset($resp_encoding, array('UTF-8', 'ISO-8859-1', 'US-ASCII')))
                        {
                                error_log('XML-RPC: xmlrpcmsg::parseResponse: invalid charset encoding of received response: '
                                          .                                                                                    $resp_encoding);
                                $resp_encoding=  $GLOBALS['xmlrpc_defencoding'];
                              }
                        $parser=  xml_parser_create($resp_encoding);


Clone Instance
2
Line Count
11
Source Line
914
Source File
libraries/phpxmlrpc/xmlrpcs.php

                                if (!in_array($req_encoding, array( 'UTF-8', 'ISO-8859-1', 'US-ASCII'
                                                                  )))
                                // the following code might be better for mb_string enabled installs, but
                                // makes the lib about 200% slower...
                                //if (!is_valid_charset($req_encoding, array('UTF-8', 'ISO-8859-1', 'US-ASCII')))
                                {
                                        error_log('XML-RPC: xmlrpc_server::parseRequest: invalid charset encoding of received request: '
                                                  .                                                                                      $req_encoding);
                                        $req_encoding=  $GLOBALS['xmlrpc_defencoding'];
                                      }
                                /// @BUG this will fail on PHP 5 if charset is not specified in the xml prologue,
                                // the encoding is not UTF8 and there are non-ascii chars in the text...
                                $parser=  xml_parser_create($req_encoding);


Clone AbstractionParameter Count: 2Parameter Bindings

// if response charset encoding is not known / supported, try to use
// the default encoding and parse the xml anyway, but log a warning...
if (!in_array( [[#variable490907a0]],array( 'UTF-8',
                                            'ISO-8859-1',
                                            'US-ASCII'
                                          )))
                                             // the following code might be better for mb_string enabled installs, but
                                             // makes the lib about 200% slower...
                                             //if (!is_valid_charset($resp_encoding, array('UTF-8', 'ISO-8859-1', 'US-ASCII')))
                                             //if (!is_valid_charset($req_encoding, array('UTF-8', 'ISO-8859-1', 'US-ASCII')))
                                             {
  error_log( [[#variable49090780]]
            .  [[#variable490907a0]]);
   [[#variable490907a0]]=$GLOBALS['xmlrpc_defencoding'];
}
/// @BUG this will fail on PHP 5 if charset is not specified in the xml prologue,
// the encoding is not UTF8 and there are non-ascii chars in the text...
$parser=xml_parser_create( [[#variable490907a0]]);
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#490907a0]]
$resp_encoding 
12[[#490907a0]]
$req_encoding 
21[[#49090780]]
'XML-RPC: xmlrpcmsg::parseResponse: invalid charset encoding of received response: ' 
22[[#49090780]]
'XML-RPC: xmlrpc_server::parseRequest: invalid charset encoding of received request: '