diff options
author | Aaron Plattner <aplattner@nvidia.com> | 2010-08-27 10:20:29 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2010-09-10 11:48:17 -0700 |
commit | cf88363db0ebb42df7cc286b85d30d7898aea840 (patch) | |
tree | cc869319ee714c64d173fc387db230ccc6bae63f /COPYING | |
parent | fa22f97af65efc2a147e9be0b7f288848965ff60 (diff) |
os: Return BadLength instead of disconnecting BigReq clients (#4565)
If a client sends a big request that's too big (i.e. bigger than
maxBigRequestSize << 2 bytes), the server just disconnects it. This makes the
client receive SIGPIPE the next time it tries to send something.
The X Test Suite sends requests that are too big when the test specifies the
TOO_LONG test type. When the client receives SIGPIPE, XTS marks it as
UNRESOLVED, which counts as a failure.
Instead, remember how long the request is supposed to be and then return that
size. Dispatch() checks the length and sends BadLength to the client. Then,
whenever oci->ignoreBytes is nonzero, ignore the data read instead of trying to
process it as a request.
Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'COPYING')
0 files changed, 0 insertions, 0 deletions