Add HTTPD-INPUT-RESPONSE response values.

This commit is contained in:
sperber 2003-02-06 15:05:15 +00:00
parent f99dbe3b99
commit 44322977fc
3 changed files with 15 additions and 3 deletions

View File

@ -167,10 +167,14 @@
(lambda ()
(let ((initial-req (parse-http-request sock options)))
(let redirect-loop ((req initial-req))
(let ((response ((httpd-options-request-handler options)
(http-url-path (request-url req))
req)))
(let response-loop ((response ((httpd-options-request-handler options)
(http-url-path (request-url req))
req)))
(cond
((input-response? response)
(response-loop
((input-response-body-maker response)
(socket:inport sock))))
((nph-response? response)
(values req response))
((eq? (response-code response) (status-code redirect))

View File

@ -24,6 +24,11 @@
nph-response?
(body nph-response-body))
(define-record-type http-input-response :http-input-response
(make-input-response body-maker)
input-response?
(body-maker input-response-body-maker))
(define-record-type http-writer-body :http-writer-body
(make-writer-body proc)
writer-body?

View File

@ -284,6 +284,9 @@
make-nph-response nph-response?
nph-response-body
make-input-response input-response?
input-response-body-maker
make-writer-body writer-body?
make-reader-writer-body reader-writer-body?
make-redirect-body redirect-body? redirect-body-location