1
0
mirror of https://github.com/apache/httpd.git synced 2026-10-23 22:49:01 +03:00

Fix broken uwsgi test on windows:

* test/modules/proxy/env.py (ProxyBackend._process): read 8192 bytes
  on Windows and 4096 elsewhere to avoid short reads on win32.

Submitted by: Paul Lodge <paullodge outlook.com>
GitHub: closes #785


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1938786 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Joe Orton
2026-10-05 07:24:48 +00:00
parent 3fc5caa57b
commit 2bb4724f4f

View File

@@ -2,6 +2,7 @@ import inspect
import logging
import os
import socket
import sys
from threading import Thread
from pyhttpd.certs import CertificateSpec
@@ -45,13 +46,14 @@ Content-Type: text/html
Content-Length: 5
Hello""".encode()
def _process(self):
_read_buffer = 8192 if sys.platform == "win32" else 4096
while not self._done:
try:
c, client_address = self._socket.accept()
try:
data = c.recv(4096)
data = c.recv(_read_buffer)
# capture request to backend
self._request = data
c.sendall(self._make_response(data))