summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKevin Ryde <user42@zip.com.au>2005-10-27 00:28:40 +0000
committerKevin Ryde <user42@zip.com.au>2005-10-27 00:28:40 +0000
commit6fc0a1b5990f6b65bf3e6f58eee82ec2f7a93ebc (patch)
tree5993d74225e0cbae3516145ed8979aafd42c83ab
parent9c0129aca25a9d8b700fe857c80485161ee8b600 (diff)
2005-10-27 Ludovic Courtès <ludovic.courtes@laas.fr>
* socket.c (scm_fill_sockaddr): No need to check NULL from scm_malloc. (scm_connect, scm_bind, scm_sendto): Accept sockaddr object. (scm_addr_vector): Renamed to _scm_from_sockaddr, update usages. (scm_from_sockaddr, scm_to_sockaddr, scm_make_socket_address, scm_c_make_socket_address): New functions. * socket.h: Add prototypes.
-rw-r--r--libguile/socket.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/libguile/socket.h b/libguile/socket.h
index dad10c441..137e669cc 100644
--- a/libguile/socket.h
+++ b/libguile/socket.h
@@ -3,7 +3,7 @@
#ifndef SCM_SOCKET_H
#define SCM_SOCKET_H
-/* Copyright (C) 1995,1996,1997,2000,2001, 2004 Free Software Foundation, Inc.
+/* Copyright (C) 1995,1996,1997,2000,2001, 2004, 2005 Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -54,6 +54,16 @@ SCM_API SCM scm_recvfrom (SCM sockfd, SCM buff_or_size, SCM flags, SCM offset, S
SCM_API SCM scm_sendto (SCM sockfd, SCM message, SCM fam, SCM address, SCM args_and_flags);
SCM_API void scm_init_socket (void);
+/* Wrapping/unwrapping address objects. */
+struct sockaddr;
+SCM_API SCM scm_from_sockaddr (const struct sockaddr *address,
+ unsigned addr_size);
+SCM_API struct sockaddr *scm_to_sockaddr (SCM address, size_t *adress_size);
+SCM_API struct sockaddr *scm_c_make_socket_address (SCM family, SCM address,
+ SCM args,
+ size_t *address_size);
+SCM_API SCM scm_make_socket_address (SCM family, SCM address, SCM args);
+
#endif /* SCM_SOCKET_H */
/*