diff options
author | Tobias Weimer <wishmaster51@googlemail.com> | 2015-09-02 21:04:37 +0000 |
---|---|---|
committer | Tobias Weimer <wishmaster51@googlemail.com> | 2015-09-02 21:04:37 +0000 |
commit | a9fc674b3971ec9f20c719f5e8c6b3dfed8c4961 (patch) | |
tree | 5f7f14fff3b488e1367ec836d4b5878ee155ffda /plugins/YAMN/src/mails | |
parent | 3e16157bf6d179040f07a89dac60f2a4a4c1c525 (diff) |
YAMN:
- many small fixes
git-svn-id: http://svn.miranda-ng.org/main/trunk@15160 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/YAMN/src/mails')
-rw-r--r-- | plugins/YAMN/src/mails/decode.cpp | 12 | ||||
-rw-r--r-- | plugins/YAMN/src/mails/mails.cpp | 2 |
2 files changed, 6 insertions, 8 deletions
diff --git a/plugins/YAMN/src/mails/decode.cpp b/plugins/YAMN/src/mails/decode.cpp index 8f8099e776..d5c49e7ebe 100644 --- a/plugins/YAMN/src/mails/decode.cpp +++ b/plugins/YAMN/src/mails/decode.cpp @@ -443,7 +443,6 @@ void ConvertCodedStringToUnicode(char *stream,WCHAR **storeto,DWORD cp,int mode) {
char *start=stream,*finder,*finderend;
char Encoding=0;
- char *DecodedResult=NULL;
if (stream==NULL)
return;
@@ -477,8 +476,8 @@ void ConvertCodedStringToUnicode(char *stream,WCHAR **storeto,DWORD cp,int mode) cp=CP_ACP;
if (Encoding != 0)
{
- int size,codeend;
- char *pcodeend;
+ int size = 0,codeend;
+ char *pcodeend = 0;
finder=finderend+2;
if (CODED(finder))
@@ -508,9 +507,8 @@ void ConvertCodedStringToUnicode(char *stream,WCHAR **storeto,DWORD cp,int mode) size=finderend-finder+1+1;
break;
}
- if (DecodedResult != NULL)
- delete[] DecodedResult;
- DecodedResult=new char[size+1];
+
+ char *DecodedResult = new char[size+1];
switch(Encoding)
{
case 'q':
@@ -540,7 +538,7 @@ void ConvertCodedStringToUnicode(char *stream,WCHAR **storeto,DWORD cp,int mode) }
delete oneWord;
oneWord = 0;
- delete[] DecodedResult; DecodedResult = 0;
+ delete[] DecodedResult;
start = finderend;
} else if (!EOS(start)) start++;
} else if (!EOS(start)) start++;
diff --git a/plugins/YAMN/src/mails/mails.cpp b/plugins/YAMN/src/mails/mails.cpp index e8793757cd..5ae21b95ef 100644 --- a/plugins/YAMN/src/mails/mails.cpp +++ b/plugins/YAMN/src/mails/mails.cpp @@ -451,7 +451,7 @@ void WINAPI TranslateHeaderFcn(char *stream,int len,struct CMimeItem **head) HYAMNMAIL WINAPI CreateNewDeleteQueueFcn(HYAMNMAIL From)
{
- HYAMNMAIL FirstMail,Browser;
+ HYAMNMAIL FirstMail,Browser = 0;
for (FirstMail=NULL;From != NULL;From=From->Next)
{
|