guile-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

guile/guile-core/libguile ChangeLog socket.c


From: Gary Houston
Subject: guile/guile-core/libguile ChangeLog socket.c
Date: Sat, 10 Mar 2001 02:30:16 -0800

CVSROOT:        /cvs
Module name:    guile
Changes by:     Gary Houston <address@hidden>   01/03/10 02:30:16

Modified files:
        guile-core/libguile: ChangeLog socket.c 

Log message:
        * socket.c: add a definition of SUN_LEN (from glibc) for when it's
        not already defined.

CVSWeb URLs:
http://subversions.gnu.org/cgi-bin/cvsweb/guile/guile-core/libguile/ChangeLog.diff?r1=1.1309&r2=1.1310
http://subversions.gnu.org/cgi-bin/cvsweb/guile/guile-core/libguile/socket.c.diff?r1=1.62&r2=1.63

Patches:
Index: guile/guile-core/libguile/ChangeLog
diff -u guile/guile-core/libguile/ChangeLog:1.1309 
guile/guile-core/libguile/ChangeLog:1.1310
--- guile/guile-core/libguile/ChangeLog:1.1309  Fri Mar  9 19:09:07 2001
+++ guile/guile-core/libguile/ChangeLog Sat Mar 10 02:30:16 2001
@@ -1,3 +1,8 @@
+2001-03-10  Gary Houston  <address@hidden>
+
+       * socket.c: add a definition of SUN_LEN (from glibc) for when it's
+       not already defined.
+
 2001-03-09  Mikael Djurfeldt  <address@hidden>
 
        * coop.c: Inserted #include <stdio.h>.
Index: guile/guile-core/libguile/socket.c
diff -u guile/guile-core/libguile/socket.c:1.62 
guile/guile-core/libguile/socket.c:1.63
--- guile/guile-core/libguile/socket.c:1.62     Fri Mar  9 15:33:41 2001
+++ guile/guile-core/libguile/socket.c  Sat Mar 10 02:30:16 2001
@@ -69,6 +69,11 @@
 #include <netdb.h>
 #include <arpa/inet.h>
 
+#if defined (HAVE_UNIX_DOMAIN_SOCKETS) && !defined (SUN_LEN)
+#define SUN_LEN(ptr) ((size_t) (((struct sockaddr_un *) 0)->sun_path) \
+                     + strlen ((ptr)->sun_path))
+#endif
+
 /* we are not currently using socklen_t.  it's not defined on all systems,
    so would need to be checked by configure.  in the meantime, plain
    int is the best alternative.  */
@@ -810,9 +815,8 @@
   else
     SCM_VALIDATE_ULONG_COPY (3, flags, flg);
 
-  /* recvfrom will not necessarily return an address.  e.g., linux
-     2.4.2 doesn't change addr or addr_size if socket is
-     AF_INET/SOCK_STREAM.  */
+  /* recvfrom will not necessarily return an address.  usually nothing
+     is returned for stream sockets.  */
   addr->sa_family = AF_UNSPEC;
   SCM_SYSCALL (rv = recvfrom (fd, buf + offset,
                              cend - offset, flg,



reply via email to

[Prev in Thread] Current Thread [Next in Thread]