2005-05-19 Paul Jakma <paul@dishone.st>

* sockunion.c: (sockunion_getsockname) use MTYPE_SOCKUNION, not TMP
	  (sockunion_getpeername) ditto
This commit is contained in:
paul 2005-05-19 01:37:50 +00:00
parent dc81807a5b
commit 2ba9a37add
2 changed files with 6 additions and 4 deletions

View File

@ -3,6 +3,8 @@
* thread.c: (thread_cancel_event) the number of pending events
cancelled is potentially useful information, dont throw it away,
pass it back to the caller.
* sockunion.c: (sockunion_getsockname) use MTYPE_SOCKUNION, not TMP
(sockunion_getpeername) ditto
2005-05-15 Paul Jakma <paul@dishone.st>

View File

@ -582,14 +582,14 @@ sockunion_getsockname (int fd)
if (name.sa.sa_family == AF_INET)
{
su = XCALLOC (MTYPE_TMP, sizeof (union sockunion));
su = XCALLOC (MTYPE_SOCKUNION, sizeof (union sockunion));
memcpy (su, &name, sizeof (struct sockaddr_in));
return su;
}
#ifdef HAVE_IPV6
if (name.sa.sa_family == AF_INET6)
{
su = XCALLOC (MTYPE_TMP, sizeof (union sockunion));
su = XCALLOC (MTYPE_SOCKUNION, sizeof (union sockunion));
memcpy (su, &name, sizeof (struct sockaddr_in6));
if (IN6_IS_ADDR_V4MAPPED (&su->sin6.sin6_addr))
@ -636,14 +636,14 @@ sockunion_getpeername (int fd)
if (name.sa.sa_family == AF_INET)
{
su = XCALLOC (MTYPE_TMP, sizeof (union sockunion));
su = XCALLOC (MTYPE_SOCKUNION, sizeof (union sockunion));
memcpy (su, &name, sizeof (struct sockaddr_in));
return su;
}
#ifdef HAVE_IPV6
if (name.sa.sa_family == AF_INET6)
{
su = XCALLOC (MTYPE_TMP, sizeof (union sockunion));
su = XCALLOC (MTYPE_SOCKUNION, sizeof (union sockunion));
memcpy (su, &name, sizeof (struct sockaddr_in6));
if (IN6_IS_ADDR_V4MAPPED (&su->sin6.sin6_addr))