diff options
Diffstat (limited to 'plugins/Db3x_mmap/src/database.cpp')
-rw-r--r-- | plugins/Db3x_mmap/src/database.cpp | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/plugins/Db3x_mmap/src/database.cpp b/plugins/Db3x_mmap/src/database.cpp index 4a0357d680..fd88e98b6f 100644 --- a/plugins/Db3x_mmap/src/database.cpp +++ b/plugins/Db3x_mmap/src/database.cpp @@ -119,3 +119,21 @@ void CDb3Base::DatabaseCorruption(TCHAR *text) Sleep(INFINITE);
}
}
+
+/////////////////////////////////////////////////////////////////////////////////////////
+
+#ifdef DBLOGGING
+void DBLog(const char *file,int line,const char *fmt,...)
+{
+ FILE *fp;
+ va_list vararg;
+ char str[1024];
+
+ va_start(vararg,fmt);
+ mir_vsnprintf(str,sizeof(str),fmt,vararg);
+ va_end(vararg);
+ fp=fopen("c:\\mirandadatabase.log.txt","at");
+ fprintf(fp,"%u: %s %d: %s\n",GetTickCount(),file,line,str);
+ fclose(fp);
+}
+#endif
|