From: havoc Date: Wed, 15 Jun 2005 01:55:55 +0000 (+0000) Subject: added debug prints to FRIK_FILE fopen/fclose builtins X-Git-Tag: xonotic-v0.1.0preview~4745 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=b63e7923de09de541925afd34739f0fd27778e97;p=xonotic%2Fdarkplaces.git added debug prints to FRIK_FILE fopen/fclose builtins git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5438 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/prvm_cmds.c b/prvm_cmds.c index c68c3ab8..c5c9879e 100644 --- a/prvm_cmds.c +++ b/prvm_cmds.c @@ -1457,6 +1457,8 @@ void VM_fopen(void) VM_FILES[filenum] = FS_Open(va("data/%s", filename), modestring, false, false); if (VM_FILES[filenum] == NULL && mode == 0) VM_FILES[filenum] = FS_Open(va("%s", filename), modestring, false, false); + if (developer.integer) + Con_Printf("fopen: %s mode %s opened as #%i\n", filename, modestring, filenum); if (VM_FILES[filenum] == NULL) PRVM_G_FLOAT(OFS_RETURN) = -1; @@ -1489,6 +1491,8 @@ void VM_fclose(void) Con_Printf("VM_fclose: no such file handle %i (or file has been closed) in %s\n", filenum, PRVM_NAME); return; } + if (developer.integer) + Con_Printf("fclose #%i\n", filenum); FS_Close(VM_FILES[filenum]); VM_FILES[filenum] = NULL; }