aboutsummaryrefslogtreecommitdiffstats
path: root/code/server/sv_client.c
diff options
context:
space:
mode:
authorthilo <thilo@edf5b092-35ff-0310-97b2-ce42778d08ea>2007-01-24 21:23:21 +0000
committerthilo <thilo@edf5b092-35ff-0310-97b2-ce42778d08ea>2007-01-24 21:23:21 +0000
commitf22191f25976f39d1467b6fd9e523fe96d900a7d (patch)
treef4384687e0aa0057b4c2c0f72701fb44a66a5ca6 /code/server/sv_client.c
parent6d74e13451e79441dc45419d5a46f4fbf0256a98 (diff)
downloadioquake3-aero-f22191f25976f39d1467b6fd9e523fe96d900a7d.tar.gz
ioquake3-aero-f22191f25976f39d1467b6fd9e523fe96d900a7d.zip
- Fix loads of format string bugs
- Fix locally looping sounds, thanks to Timbo git-svn-id: svn://svn.icculus.org/quake3/trunk@1037 edf5b092-35ff-0310-97b2-ce42778d08ea
Diffstat (limited to 'code/server/sv_client.c')
-rw-r--r--code/server/sv_client.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/code/server/sv_client.c b/code/server/sv_client.c
index 3a4a74b..d2454dc 100644
--- a/code/server/sv_client.c
+++ b/code/server/sv_client.c
@@ -679,7 +679,7 @@ Abort a download if in progress
*/
void SV_StopDownload_f( client_t *cl ) {
if (*cl->downloadName)
- Com_DPrintf( "clientDownload: %d : file \"%s\" aborted\n", cl - svs.clients, cl->downloadName );
+ Com_DPrintf( "clientDownload: %d : file \"%s\" aborted\n", (int) (cl - svs.clients), cl->downloadName );
SV_CloseDownload( cl );
}
@@ -710,11 +710,11 @@ void SV_NextDownload_f( client_t *cl )
int block = atoi( Cmd_Argv(1) );
if (block == cl->downloadClientBlock) {
- Com_DPrintf( "clientDownload: %d : client acknowledge of block %d\n", cl - svs.clients, block );
+ Com_DPrintf( "clientDownload: %d : client acknowledge of block %d\n", (int) (cl - svs.clients), block );
// Find out if we are done. A zero-length block indicates EOF
if (cl->downloadBlockSize[cl->downloadClientBlock % MAX_DOWNLOAD_WINDOW] == 0) {
- Com_Printf( "clientDownload: %d : file \"%s\" completed\n", cl - svs.clients, cl->downloadName );
+ Com_Printf( "clientDownload: %d : file \"%s\" completed\n", (int) (cl - svs.clients), cl->downloadName );
SV_CloseDownload( cl );
return;
}
@@ -809,11 +809,11 @@ void SV_WriteDownloadToClient( client_t *cl , msg_t *msg )
// cannot auto-download file
if(unreferenced)
{
- Com_Printf("clientDownload: %d : \"%s\" is not referenced and cannot be downloaded.\n", cl - svs.clients, cl->downloadName);
+ Com_Printf("clientDownload: %d : \"%s\" is not referenced and cannot be downloaded.\n", (int) (cl - svs.clients), cl->downloadName);
Com_sprintf(errorMessage, sizeof(errorMessage), "File \"%s\" is not referenced and cannot be downloaded.", cl->downloadName);
}
else if (idPack) {
- Com_Printf("clientDownload: %d : \"%s\" cannot download id pk3 files\n", cl - svs.clients, cl->downloadName);
+ Com_Printf("clientDownload: %d : \"%s\" cannot download id pk3 files\n", (int) (cl - svs.clients), cl->downloadName);
if (missionPack) {
Com_sprintf(errorMessage, sizeof(errorMessage), "Cannot autodownload Team Arena file \"%s\"\n"
"The Team Arena mission pack can be found in your local game store.", cl->downloadName);
@@ -825,7 +825,7 @@ void SV_WriteDownloadToClient( client_t *cl , msg_t *msg )
else if ( !(sv_allowDownload->integer & DLF_ENABLE) ||
(sv_allowDownload->integer & DLF_NO_UDP) ) {
- Com_Printf("clientDownload: %d : \"%s\" download disabled", cl - svs.clients, cl->downloadName);
+ Com_Printf("clientDownload: %d : \"%s\" download disabled", (int) (cl - svs.clients), cl->downloadName);
if (sv_pure->integer) {
Com_sprintf(errorMessage, sizeof(errorMessage), "Could not download \"%s\" because autodownloading is disabled on the server.\n\n"
"You will need to get this file elsewhere before you "
@@ -839,7 +839,7 @@ void SV_WriteDownloadToClient( client_t *cl , msg_t *msg )
} else {
// NOTE TTimo this is NOT supposed to happen unless bug in our filesystem scheme?
// if the pk3 is referenced, it must have been found somewhere in the filesystem
- Com_Printf("clientDownload: %d : \"%s\" file not found on server\n", cl - svs.clients, cl->downloadName);
+ Com_Printf("clientDownload: %d : \"%s\" file not found on server\n", (int) (cl - svs.clients), cl->downloadName);
Com_sprintf(errorMessage, sizeof(errorMessage), "File \"%s\" not found on server for autodownloading.\n", cl->downloadName);
}
MSG_WriteByte( msg, svc_download );
@@ -851,7 +851,7 @@ void SV_WriteDownloadToClient( client_t *cl , msg_t *msg )
return;
}
- Com_Printf( "clientDownload: %d : beginning \"%s\"\n", cl - svs.clients, cl->downloadName );
+ Com_Printf( "clientDownload: %d : beginning \"%s\"\n", (int) (cl - svs.clients), cl->downloadName );
// Init
cl->downloadCurrentBlock = cl->downloadClientBlock = cl->downloadXmitBlock = 0;
@@ -960,7 +960,7 @@ void SV_WriteDownloadToClient( client_t *cl , msg_t *msg )
MSG_WriteData( msg, cl->downloadBlocks[curindex], cl->downloadBlockSize[curindex] );
}
- Com_DPrintf( "clientDownload: %d : writing block %d\n", cl - svs.clients, cl->downloadXmitBlock );
+ Com_DPrintf( "clientDownload: %d : writing block %d\n", (int) (cl - svs.clients), cl->downloadXmitBlock );
// Move on to the next block
// It will get sent with next snap shot. The rate will keep us in line.
@@ -1580,7 +1580,7 @@ void SV_ExecuteClientMessage( client_t *cl, msg_t *msg ) {
} else if ( c == clc_moveNoDelta ) {
SV_UserMove( cl, msg, qfalse );
} else if ( c != clc_EOF ) {
- Com_Printf( "WARNING: bad command byte for client %i\n", cl - svs.clients );
+ Com_Printf( "WARNING: bad command byte for client %i\n", (int) (cl - svs.clients) );
}
// if ( msg->readcount != msg->cursize ) {
// Com_Printf( "WARNING: Junk at end of packet for client %i\n", cl - svs.clients );