summaryrefslogtreecommitdiff
path: root/Xtransutil.c
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@sun.com>2006-08-24 14:46:42 -0700
committerAlan Coopersmith <alan.coopersmith@sun.com>2006-08-24 14:46:42 -0700
commit02ffb657b023d9b2a2c6c1d2417da8dcb96aa4b2 (patch)
tree78591680fd913c8822d9fc34286d7312f2ad09b5 /Xtransutil.c
parent3d5e7dd18c8836065c4835740211c10747b18abd (diff)
downloadxorg-lib-libxtrans-02ffb657b023d9b2a2c6c1d2417da8dcb96aa4b2.tar.gz
More sprintf -> snprintf conversions
Diffstat (limited to 'Xtransutil.c')
-rw-r--r--Xtransutil.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Xtransutil.c b/Xtransutil.c
index 253e8b0..cc57193 100644
--- a/Xtransutil.c
+++ b/Xtransutil.c
@@ -300,7 +300,7 @@ TRANS(GetMyNetworkId) (XtransConnInfo ciptr)
#endif
portnum = ntohs (saddr->sin_port);
- sprintf (portnumbuf, "%d", portnum);
+ snprintf (portnumbuf, sizeof(portnumbuf), "%d", portnum);
networkId = (char *) xalloc (3 + strlen (transName) +
strlen (hostnamebuf) + strlen (portnumbuf));
sprintf (networkId, "%s/%s:%s", transName, hostnamebuf, portnumbuf);