summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNeal Norwitz <nnorwitz@gmail.com>2007-10-24 03:52:50 +0000
committerNeal Norwitz <nnorwitz@gmail.com>2007-10-24 03:52:50 +0000
commit4b2a6dbf60da3caa1bec8d40886f8330dae3da40 (patch)
tree61a922785450d96b5d2d92aa95a746cc22d54346
parent4aa5f4bc5a0baf529d41fdd645f474a3b23aa9b0 (diff)
downloadcpython-git-4b2a6dbf60da3caa1bec8d40886f8330dae3da40.tar.gz
Backport 58618:
Issue 1307 by Derek Shockey, fix the same bug for RCPT.
-rwxr-xr-xLib/smtpd.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/smtpd.py b/Lib/smtpd.py
index 4aa34763ec..e09774f2d9 100755
--- a/Lib/smtpd.py
+++ b/Lib/smtpd.py
@@ -237,7 +237,7 @@ class SMTPChannel(asynchat.async_chat):
if not self.__mailfrom:
self.push('503 Error: need MAIL command')
return
- address = self.__getaddr('TO:', arg)
+ address = self.__getaddr('TO:', arg) if arg else None
if not address:
self.push('501 Syntax: RCPT TO: <address>')
return