diff options
Diffstat (limited to 'plugins/WhenWasIt/src/utils.cpp')
-rw-r--r-- | plugins/WhenWasIt/src/utils.cpp | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/plugins/WhenWasIt/src/utils.cpp b/plugins/WhenWasIt/src/utils.cpp index 11f10e26e6..56db42471e 100644 --- a/plugins/WhenWasIt/src/utils.cpp +++ b/plugins/WhenWasIt/src/utils.cpp @@ -31,30 +31,30 @@ int LogInit() int Log(char *format, ...)
{
- #ifdef _DEBUG
- char str[4096];
- va_list vararg;
- int tBytes;
- FILE *fout = fopen(LOG_FILE, "at");
- if (!fout)
- return -1;
-
- time_t tNow = time(NULL);
- struct tm *now = localtime(&tNow);
- strftime(str, sizeof(str), "%d %b %Y @ %H:%M:%S: ", now);
- fputs(str, fout);
- va_start(vararg, format);
-
- tBytes = mir_vsnprintf(str, sizeof(str), format, vararg);
- if (tBytes > 0)
- str[tBytes] = 0;
-
- va_end(vararg);
- if (str[strlen(str) - 1] != '\n')
- strcat(str, "\n");
- fputs(str, fout);
- fclose(fout);
- #endif
+#ifdef _DEBUG
+ char str[4096];
+ va_list vararg;
+ int tBytes;
+ FILE *fout = fopen(LOG_FILE, "at");
+ if (!fout)
+ return -1;
+
+ time_t tNow = time(NULL);
+ struct tm *now = localtime(&tNow);
+ strftime(str, sizeof(str), "%d %b %Y @ %H:%M:%S: ", now);
+ fputs(str, fout);
+ va_start(vararg, format);
+
+ tBytes = mir_vsnprintf(str, sizeof(str), format, vararg);
+ if (tBytes > 0)
+ str[tBytes] = 0;
+
+ va_end(vararg);
+ if (str[strlen(str) - 1] != '\n')
+ strcat(str, "\n");
+ fputs(str, fout);
+ fclose(fout);
+#endif
return 0;
}
|