Consistently use non-blocking
This commit is contained in:
parent
4e564b4814
commit
7e55db0de7
3 changed files with 5 additions and 5 deletions
|
@ -21,7 +21,7 @@
|
|||
#:use-module (web uri)
|
||||
#:use-module (web client)
|
||||
#:export (non-blocking-port
|
||||
nonblocking-open-socket-for-uri))
|
||||
non-blocking-open-socket-for-uri))
|
||||
|
||||
(define (non-blocking-port port)
|
||||
"Make PORT non-blocking and return it."
|
||||
|
@ -30,8 +30,8 @@
|
|||
(fcntl port F_SETFL (logior O_NONBLOCK flags)))
|
||||
port))
|
||||
|
||||
(define* (nonblocking-open-socket-for-uri uri
|
||||
#:key (verify-certificate? #t))
|
||||
(define* (non-blocking-open-socket-for-uri uri
|
||||
#:key (verify-certificate? #t))
|
||||
(define tls-wrap
|
||||
(@@ (web client) tls-wrap))
|
||||
|
||||
|
|
|
@ -26,6 +26,6 @@
|
|||
(response-code
|
||||
(http-get
|
||||
uri
|
||||
#:port (nonblocking-open-socket-for-uri uri)))))))
|
||||
#:port (non-blocking-open-socket-for-uri uri)))))))
|
||||
|
||||
(display "non-blocking test finished successfully\n")
|
||||
|
|
|
@ -25,6 +25,6 @@
|
|||
(response-code
|
||||
(http-get
|
||||
uri
|
||||
#:port (nonblocking-open-socket-for-uri uri)))))))
|
||||
#:port (non-blocking-open-socket-for-uri uri)))))))
|
||||
|
||||
(display "web-server test finished successfully\n")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue