diff options
Diffstat (limited to 'Xtransutil.c')
-rw-r--r-- | Xtransutil.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Xtransutil.c b/Xtransutil.c index dd36cae..4128990 100644 --- a/Xtransutil.c +++ b/Xtransutil.c @@ -197,11 +197,11 @@ TRANS(ConvertAddress)(int *familyp, int *addrlenp, Xtransaddr **addrp) if (len > 0) { if (*addrp && *addrlenp < (len + 1)) { - xfree ((char *) *addrp); + free ((char *) *addrp); *addrp = NULL; } if (!*addrp) - *addrp = (Xtransaddr *) xalloc (len + 1); + *addrp = (Xtransaddr *) malloc (len + 1); if (*addrp) { strcpy ((char *) *addrp, hostnamebuf); *addrlenp = len; @@ -212,7 +212,7 @@ TRANS(ConvertAddress)(int *familyp, int *addrlenp, Xtransaddr **addrp) else { if (*addrp) - xfree ((char *) *addrp); + free ((char *) *addrp); *addrp = NULL; *addrlenp = 0; } @@ -255,7 +255,7 @@ TRANS(GetMyNetworkId) (XtransConnInfo ciptr) case AF_UNIX: { struct sockaddr_un *saddr = (struct sockaddr_un *) addr; - networkId = (char *) xalloc (3 + strlen (transName) + + networkId = (char *) malloc (3 + strlen (transName) + strlen (hostnamebuf) + strlen (saddr->sun_path)); sprintf (networkId, "%s/%s:%s", transName, hostnamebuf, saddr->sun_path); @@ -285,7 +285,7 @@ TRANS(GetMyNetworkId) (XtransConnInfo ciptr) portnum = ntohs (saddr->sin_port); snprintf (portnumbuf, sizeof(portnumbuf), "%d", portnum); - networkId = (char *) xalloc (3 + strlen (transName) + + networkId = (char *) malloc (3 + strlen (transName) + strlen (hostnamebuf) + strlen (portnumbuf)); sprintf (networkId, "%s/%s:%s", transName, hostnamebuf, portnumbuf); break; @@ -418,7 +418,7 @@ TRANS(GetPeerNetworkId) (XtransConnInfo ciptr) } - hostname = (char *) xalloc ( + hostname = (char *) malloc ( strlen (ciptr->transptr->TransName) + strlen (addr) + 2); strcpy (hostname, ciptr->transptr->TransName); strcat (hostname, "/"); |