aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Hoa V. DINH <dinh.viet.hoa@gmail.com>2016-04-16 18:00:38 -0700
committerGravatar Hoa V. DINH <dinh.viet.hoa@gmail.com>2016-04-16 18:00:38 -0700
commitdc9eec29eb121d3d37c42c0c8947e53998a16dba (patch)
tree3a99e4f658a0bd08ecd471d90c6d7b5476b7b158
parent631581a70eb9f8f36c3a6b5e55f4ec223f85301e (diff)
Don't crash if it couldn't be detected
-rw-r--r--src/core/abstract/MCMessageHeader.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/core/abstract/MCMessageHeader.cpp b/src/core/abstract/MCMessageHeader.cpp
index e16f27af..d5a152f5 100644
--- a/src/core/abstract/MCMessageHeader.cpp
+++ b/src/core/abstract/MCMessageHeader.cpp
@@ -527,7 +527,9 @@ void MessageHeader::importIMFFields(struct mailimf_fields * fields)
fieldValue = field->fld_data.fld_optional_field->fld_value;
fieldValueStr = String::stringByDecodingMIMEHeaderValue(fieldValue);
- setExtraHeader(fieldNameStr, fieldValueStr);
+ if (fieldValueStr != NULL) {
+ setExtraHeader(fieldNameStr, fieldValueStr);
+ }
}
}
}