]> Cypherpunks repositories - gostls13.git/commitdiff
net/mail: fix build.
authorDavid Symonds <dsymonds@golang.org>
Tue, 11 Aug 2015 06:36:40 +0000 (16:36 +1000)
committerDavid Symonds <dsymonds@golang.org>
Tue, 11 Aug 2015 06:42:12 +0000 (06:42 +0000)
Change-Id: I8f5c72c6c0db015c06d564523bab35d97d934578
Reviewed-on: https://go-review.googlesource.com/13510
Reviewed-by: Michael McGreevy <mcgreevy@golang.org>
Reviewed-by: David Symonds <dsymonds@golang.org>
src/net/mail/message.go
src/net/mail/message_test.go

index 8a89f9b0c077f4fa322421937bba9f11a981adce..266ac50a38dee1b82b8effbdc65b90a4dc008a64 100644 (file)
@@ -177,7 +177,7 @@ func (a *Address) String() string {
                // treat the whole address as local-part.
                local = a.Address
        } else {
-               local, domain := a.Address[:at], a.Address[at+1:]
+               local, domain = a.Address[:at], a.Address[at+1:]
        }
 
        // Add quotes if needed
index c6b412c181fe513eb53df961bc336bc489abe2b8..1b422743f95fb4656265d5695529dee0ae6757c9 100644 (file)
@@ -485,7 +485,7 @@ func TestAddressFormatting(t *testing.T) {
                },
                { // https://golang.org/issue/12098
                        &Address{Name: "Rob", Address: ""},
-                       `"Rob" <>`,
+                       `"Rob" <@>`,
                },
                { // https://golang.org/issue/12098
                        &Address{Name: "Rob", Address: "@"},