Commit 93af6778 authored by Daniel Cormier's avatar Daniel Cormier Committed by Brad Fitzpatrick
Browse files

net/textproto: properly write terminating sequence if DotWriter is closed with no writes

Fixed textproto.Writer.DotWriter() to properly write \r\n.\r\n to the buffer
when Close() is called without any bytes written. This properly writes the
terminating sequence outlined in RFC 5321 section 4.1.1.4 and RFC 3977
section 3.1.1, even when no other bytes are written.

Change-Id: I262fd2963ee76fff7ffae8e3cb0e86255694b361
Reviewed-on: https://go-review.googlesource.com/c/go/+/77350


Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
parent 4d23cbc6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment