mirror of
https://github.com/ashinn/chibi-scheme.git
synced 2025-07-07 05:06:37 +02:00
Adding an interface to socketpair.
This commit is contained in:
parent
1bd9a79e71
commit
2f8ef980d6
2 changed files with 7 additions and 1 deletions
|
@ -1,7 +1,7 @@
|
|||
|
||||
(define-library (chibi net)
|
||||
(export sockaddr? address-info? get-address-info make-address-info
|
||||
socket connect bind accept listen
|
||||
socket connect bind accept listen open-socket-pair
|
||||
with-net-io open-net-io make-listener-socket
|
||||
address-info-family address-info-socket-type address-info-protocol
|
||||
address-info-address address-info-address-length address-info-next
|
||||
|
|
|
@ -48,6 +48,12 @@
|
|||
|
||||
(define-c int connect (fileno sockaddr int))
|
||||
|
||||
;;> Returns a list of 2 new sockets, the input and output end of a new
|
||||
;;> pipe, respectively.
|
||||
|
||||
(define-c errno (open-socket-pair "socketpair")
|
||||
(int int int (result (array fileno 2))))
|
||||
|
||||
(define-c-const int (address-family/unix "AF_UNIX"))
|
||||
(define-c-const int (address-family/inet "AF_INET"))
|
||||
(define-c-const int (socket-type/stream "SOCK_STREAM"))
|
||||
|
|
Loading…
Add table
Reference in a new issue