Skip to content

net/smtp: func Rcpt buries SMTP response code #8564

Description

@gopherbot

by czaries:

I am building a program that relies on an SMTP status code being returned after a call
to RCPT over SMTP, and the go net/smtp buries this result with an underscore variable,
and the Rcpt function returns nothing on success, instead of the SMTP status code it
could return to be more useful:

http://golang.org/src/pkg/net/smtp/smtp.go line #240 (at time of writing)

Is there any way I can get the SMTP status code from a RCPT call another way?

Looking for one of these: http://www.greenend.org.uk/rjk/tech/smtpreplies.html

RCPT will typically either return 250 (okay) or 550 (no such user).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions