| 157 | } |
| 158 | |
| 159 | void QHttpResponse::write(const QByteArray &data) |
| 160 | { |
| 161 | if (m_finished) { |
| 162 | #ifdef DEBUG |
| 163 | qWarning() << "QHttpResponse::write() Cannot write body after response has finished."; |
| 164 | #endif |
| 165 | return; |
| 166 | } |
| 167 | |
| 168 | if (!m_headerWritten) { |
| 169 | #ifdef DEBUG |
| 170 | qWarning() << "QHttpResponse::write() You must call writeHead() before writing body data."; |
| 171 | #endif |
| 172 | return; |
| 173 | } |
| 174 | |
| 175 | m_connection->write(data); |
| 176 | } |
| 177 | |
| 178 | void QHttpResponse::flush() |
| 179 | { |
no outgoing calls
no test coverage detected