mirror of
https://github.com/foxcpp/maddy.git
synced 2025-04-06 06:27:38 +03:00
msgpipeline: Fix to use Raw from go-message 0.12
This commit is contained in:
parent
4498462abb
commit
e85e6b24bd
3 changed files with 13 additions and 3 deletions
|
@ -171,7 +171,11 @@ func (cr *checkRunner) runAndMergeResults(states []module.CheckState, runner fun
|
|||
if subCheckRes.Header.Len() != 0 {
|
||||
data.headerLock.Lock()
|
||||
for field := subCheckRes.Header.Fields(); field.Next(); {
|
||||
cr.mergedRes.Header.AddRaw(field.Raw())
|
||||
formatted, err := field.Raw()
|
||||
if err != nil {
|
||||
cr.log.Error("malformed header field added by check", err)
|
||||
}
|
||||
cr.mergedRes.Header.AddRaw(formatted)
|
||||
}
|
||||
data.headerLock.Unlock()
|
||||
}
|
||||
|
@ -303,7 +307,11 @@ func (cr *checkRunner) applyResults(hostname string, header *textproto.Header) e
|
|||
}
|
||||
|
||||
for field := cr.mergedRes.Header.Fields(); field.Next(); {
|
||||
header.AddRaw(field.Raw())
|
||||
formatted, err := field.Raw()
|
||||
if err != nil {
|
||||
cr.log.Error("malformed header field added by check", err)
|
||||
}
|
||||
header.AddRaw(formatted)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue