diff --git a/src/d_clisrv.c b/src/d_clisrv.c
index 46f8a9a10533df590ab852d45c9d2559a7e17f35..7d0e44b45b3496c7ee0bc3f8a28937e0ffde2bf1 100644
--- a/src/d_clisrv.c
+++ b/src/d_clisrv.c
@@ -1157,7 +1157,7 @@ static inline void CL_DrawConnectionStatus(void)
 		if (lastfilenum != -1)
 		{
 			INT32 dldlength;
-			static char tempname[32];
+			static char tempname[28];
 			fileneeded_t *file = &fileneeded[lastfilenum];
 			char *filename = file->filename;
 
@@ -1172,16 +1172,16 @@ static inline void CL_DrawConnectionStatus(void)
 			// offset filename to just the name only part
 			filename += strlen(filename) - nameonlylength(filename);
 
-			if (strlen(filename) > 31) // too long to display fully
+			if (strlen(filename) > sizeof(tempname)-1) // too long to display fully
 			{
-				size_t endhalfpos = strlen(filename)-12;
-				// display as first 16 chars + ... + last 12 chars
-				// which should add up to 31 if our math(s) is correct
-				snprintf(tempname, 31, "%.16s...%.12s", filename, filename+endhalfpos);
+				size_t endhalfpos = strlen(filename)-10;
+				// display as first 14 chars + ... + last 10 chars
+				// which should add up to 27 if our math(s) is correct
+				snprintf(tempname, sizeof(tempname), "%.14s...%.10s", filename, filename+endhalfpos);
 			}
 			else // we can copy the whole thing in safely
 			{
-				strncpy(tempname, filename, 31);
+				strncpy(tempname, filename, sizeof(tempname)-1);
 			}
 
 			V_DrawCenteredString(BASEVIDWIDTH/2, BASEVIDHEIGHT-24-32, V_YELLOWMAP,