version 1.167, 2009/10/09 05:31:06
|
version 1.168, 2010/02/01 11:40:17
|
|
|
#define _socketWriteError() \ | #define _socketWriteError() \ |
do \ | do \ |
{ \ | { \ |
|
String failureText = PEGASUS_SYSTEM_NETWORK_ERRORMSG; \ |
|
\ |
PEG_TRACE((TRC_DISCARDED_DATA, Tracer::LEVEL1, \ | PEG_TRACE((TRC_DISCARDED_DATA, Tracer::LEVEL1, \ |
"Socket write failed with error %d; could not write response " \ |
"Could not write response to client. Client may have timed out. " \ |
"to client. (Client may have timed out.)", \ |
"Socket write failed with error: %s ", \ |
getSocketError())); \ |
(const char*)failureText.getCString())); \ |
throw Exception("socket write error"); \ |
\ |
|
throw SocketWriteError(failureText); \ |
} \ | } \ |
while (0) | while (0) |
| |
|
|
} | } |
| |
// If there is an internal error on this connection, just return | // If there is an internal error on this connection, just return |
// from here if the current message is not the last message becasue |
// from here if the current message is not the last message because |
// this connection will be closed once all messages are received. | // this connection will be closed once all messages are received. |
if (_internalError) | if (_internalError) |
{ | { |
|
|
| |
} // try | } // try |
| |
|
catch (SocketWriteError &e) |
|
{ |
|
// On the server side, the socket write error is suppressed |
|
// and not handled as an internal error. |
|
httpStatusString = e.getMessage(); |
|
} |
catch (Exception &e) | catch (Exception &e) |
{ | { |
httpStatusString = e.getMessage(); | httpStatusString = e.getMessage(); |