private function sendError() { if ($this->onSendError) { call_user_func($this->onSendError, $this->error); } ob_clean(); $this->output->write(HproseTags::TagError); $writer = new HproseSimpleWriter($this->output); $writer->writeString($this->error); $this->output->write(HproseTags::TagEnd); ob_end_flush(); }