Archived
1
0

Merge pull request #166 from cathugger/master

srnd: fix multipart message parsing
This commit is contained in:
Jeff 2018-12-08 16:02:38 -05:00 committed by GitHub
commit 7e56a9b9f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -632,7 +632,7 @@ func read_message_body(body io.Reader, hdr map[string][]string, store ArticleSto
body = io.TeeReader(body, wr) body = io.TeeReader(body, wr)
} }
boundary, ok := params["boundary"] boundary, ok := params["boundary"]
if content_type == "multipart/mixed" && ok { if strings.HasPrefix(media_type, "multipart/") && ok {
partReader := multipart.NewReader(body, boundary) partReader := multipart.NewReader(body, boundary)
for { for {
part, err := partReader.NextPart() part, err := partReader.NextPart()