mustHaveFieldNameColon ensures that, per RFC 7230, the field-name is on a single line, so the first line must contain a colon.
(line []byte)
| 319 | // field-name is on a single line, so the first line must |
| 320 | // contain a colon. |
| 321 | func mustHaveFieldNameColon(line []byte) error { |
| 322 | if bytes.IndexByte(line, ':') < 0 { |
| 323 | return protocolError(fmt.Sprintf("malformed MIME header: missing colon: %q", line)) |
| 324 | } |
| 325 | return nil |
| 326 | } |
| 327 | |
| 328 | var nl = []byte("\n") |
| 329 |
nothing calls this directly
no test coverage detected
searching dependent graphs…