Check HTTP response code in XMLRPC client
darcs-hash:20090303193527-7ad00-82bb49362732ec221c7cdab41050d402ea125938.gz
This commit is contained in:
parent
5dc1766c6b
commit
926d4c4ee8
1 changed files with 6 additions and 0 deletions
|
@ -521,6 +521,12 @@ class IXR_Client extends DokuHTTPClient {
|
|||
return false;
|
||||
}
|
||||
|
||||
// Check HTTP Response code
|
||||
if($this->status < 200 || $this->status > 206){
|
||||
$this->xmlerror = new IXR_Error(-32300, 'transport error - HTTP status '.$this->status);
|
||||
return false;
|
||||
}
|
||||
|
||||
// Now parse what we've got back
|
||||
$this->message = new IXR_Message($this->resp_body);
|
||||
if (!$this->message->parse()) {
|
||||
|
|
Loading…
Reference in a new issue