aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/basetypes/MCDataStreamDecoder.cpp
diff options
context:
space:
mode:
authorGravatar Dmitry Isaikin <isaikin-dmitry@yandex.ru>2016-07-06 10:17:28 +0300
committerGravatar HoĆ  V. DINH <dinh.viet.hoa@gmail.com>2016-07-06 00:17:28 -0700
commit1e77049bf421997de9d04a6d1e1dde4ce065affe (patch)
treef6358a20850a4f440d870ec857428c7f071160cf /src/core/basetypes/MCDataStreamDecoder.cpp
parent17df6ae7c456cc27a316aa0d7b6c83066adb3c49 (diff)
Use libetpan API for fetching whole IMAP attachment to file (#1461)
Diffstat (limited to 'src/core/basetypes/MCDataStreamDecoder.cpp')
-rw-r--r--src/core/basetypes/MCDataStreamDecoder.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/core/basetypes/MCDataStreamDecoder.cpp b/src/core/basetypes/MCDataStreamDecoder.cpp
index 120cfb65..3b24c56e 100644
--- a/src/core/basetypes/MCDataStreamDecoder.cpp
+++ b/src/core/basetypes/MCDataStreamDecoder.cpp
@@ -88,6 +88,10 @@ ErrorCode DataStreamDecoder::appendDecodedData(Data * decodedData)
return ErrorFile;
}
+ if (decodedData->length() == 0) {
+ return ErrorNone;
+ }
+
if (mFile == NULL) {
mFile = fopen(mFilename->fileSystemRepresentation(), "wb");