This commit is contained in:
barant committed 2020-08-05 11:57:35 -07:00
1 parent 591705f897
commit 4f95b4591b
4 files changed
+16 -10

No files matched your search

+8 -5
View File
@@ -12,14 +12,16 @@ namespace coreutils {
parse(in);
}
void IMFMessage::parse(PString &in) {
bool IMFMessage::parse(PString &in) {
coreutils::Log(coreutils::LOG_DEBUG_4) << "parse [" << in.str() << "]";
if(in.size() == 0)
return;
while(!in.ifNext("\r\n") && !in.eod()) {
if(in.str() != "") {
headers.emplace_back(in);
return true;
}
coreutils::Log(coreutils::LOG_DEBUG_2) << "End of header with Content Type = " << getHeader("Content-Type") << " for " << getHeader("Content-Length") << " bytes.";
std::string type = getHeader("Content-Type");
@@ -32,6 +34,7 @@ namespace coreutils {
body = new IMFPlainText(in);
else
body = new IMFBody();
return false;
}
void IMFMessage::output(std::stringstream &out) {