707 |
SCM_VALIDATE_CONS (which_arg + 1, *args); |
SCM_VALIDATE_CONS (which_arg + 1, *args); |
708 |
SCM_VALIDATE_INUM_COPY (which_arg + 1, SCM_CAR (*args), port); |
SCM_VALIDATE_INUM_COPY (which_arg + 1, SCM_CAR (*args), port); |
709 |
*args = SCM_CDR (*args); |
*args = SCM_CDR (*args); |
710 |
soka = (struct sockaddr_in *) malloc (sizeof (struct sockaddr_in)); |
soka = (struct sockaddr_in *) scm_malloc (sizeof (struct sockaddr_in)); |
711 |
if (!soka) |
if (!soka) |
712 |
scm_memory_error (proc); |
scm_memory_error (proc); |
713 |
/* 4.4BSD-style interface includes sin_len member and defines SIN_LEN, |
/* 4.4BSD-style interface includes sin_len member and defines SIN_LEN, |
745 |
*args = SCM_CDR (*args); |
*args = SCM_CDR (*args); |
746 |
} |
} |
747 |
} |
} |
748 |
soka = (struct sockaddr_in6 *) malloc (sizeof (struct sockaddr_in6)); |
soka = (struct sockaddr_in6 *) scm_malloc (sizeof (struct sockaddr_in6)); |
749 |
if (!soka) |
if (!soka) |
750 |
scm_memory_error (proc); |
scm_memory_error (proc); |
751 |
#ifdef SIN_LEN6 |
#ifdef SIN_LEN6 |
777 |
member of the structure. */ |
member of the structure. */ |
778 |
addr_size = sizeof (struct sockaddr_un) |
addr_size = sizeof (struct sockaddr_un) |
779 |
+ max (0, SCM_STRING_LENGTH (address) + 1 - (sizeof soka->sun_path)); |
+ max (0, SCM_STRING_LENGTH (address) + 1 - (sizeof soka->sun_path)); |
780 |
soka = (struct sockaddr_un *) malloc (addr_size); |
soka = (struct sockaddr_un *) scm_malloc (addr_size); |
781 |
if (!soka) |
if (!soka) |
782 |
scm_memory_error (proc); |
scm_memory_error (proc); |
783 |
memset (soka, 0, addr_size); /* for sun_len: see sin_len above. */ |
memset (soka, 0, addr_size); /* for sun_len: see sin_len above. */ |