diff options
author | George Hazan <george.hazan@gmail.com> | 2013-08-06 08:33:44 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2013-08-06 08:33:44 +0000 |
commit | fbed4e49ff41a49e2b8b09e0ccc1268aeffbada1 (patch) | |
tree | 54c8ef840bbbbc2f12faf3c00700adb1b2741ff9 /plugins/TabSRMM/src/chat/log.cpp | |
parent | e2a9e8224e94127cc73cf62ebfb2a8dfee078c0c (diff) |
- DoTrimMessage removed and replaced with rtrim()
- contactcache.cpp moved from a linked list to a sorted list
git-svn-id: http://svn.miranda-ng.org/main/trunk@5598 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/TabSRMM/src/chat/log.cpp')
-rw-r--r-- | plugins/TabSRMM/src/chat/log.cpp | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/plugins/TabSRMM/src/chat/log.cpp b/plugins/TabSRMM/src/chat/log.cpp index 37930006af..25ff4df187 100644 --- a/plugins/TabSRMM/src/chat/log.cpp +++ b/plugins/TabSRMM/src/chat/log.cpp @@ -517,13 +517,14 @@ static void Log_Append(char **buffer, int *cbBufferEnd, int *cbBufferAlloced, co static int Log_AppendRTF(LOGSTREAMDATA* streamData, BOOL simpleMode, char **buffer, int *cbBufferEnd, int *cbBufferAlloced, const TCHAR *fmt, ...)
{
va_list va;
- int lineLen, textCharsCount = 0;
- TCHAR* line = (TCHAR*)alloca(8001 * sizeof(TCHAR));
- char* d;
+ int textCharsCount = 0;
+ char *d;
+ TCHAR *line = (TCHAR*)alloca(8001 * sizeof(TCHAR));
va_start(va, fmt);
- lineLen = mir_vsntprintf(line, 8000, fmt, va);
- if (lineLen < 0) lineLen = 8000;
+ int lineLen = mir_vsntprintf(line, 8000, fmt, va);
+ if (lineLen < 0)
+ lineLen = 8000;
line[lineLen] = 0;
va_end(va);
@@ -546,9 +547,7 @@ static int Log_AppendRTF(LOGSTREAMDATA* streamData, BOOL simpleMode, char **buff CopyMemory(d, "\\line ", 6);
d += 6;
} else if (*line == '%' && !simpleMode) {
- char szTemp[200];
-
- szTemp[0] = '\0';
+ char szTemp[200]; szTemp[0] = '\0';
switch (*++line) {
case '\0':
case '%':
@@ -559,7 +558,6 @@ static int Log_AppendRTF(LOGSTREAMDATA* streamData, BOOL simpleMode, char **buff case 'f':
if (g_Settings.bStripFormat || streamData->bStripFormat)
line += 2;
-
else if (line[1] != '\0' && line[2] != '\0') {
TCHAR szTemp3[3], c = *line;
int col;
|