Skip to content

Commit 033c58a

Browse files
committed
remove smtpd dead code (closes #23873)
Patch by Hoolean.
1 parent b32fb8d commit 033c58a

1 file changed

Lines changed: 0 additions & 9 deletions

File tree

Lib/smtpd.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -476,9 +476,6 @@ def smtp_MAIL(self, arg):
476476
if not self.extended_smtp and params:
477477
self.push(syntaxerr)
478478
return
479-
if not address:
480-
self.push(syntaxerr)
481-
return
482479
if self.mailfrom:
483480
self.push('503 Error: nested MAIL command')
484481
return
@@ -529,15 +526,9 @@ def smtp_RCPT(self, arg):
529526
else:
530527
self.push(syntaxerr)
531528
return
532-
if not address:
533-
self.push(syntaxerr)
534-
return
535529
if params and len(params.keys()) > 0:
536530
self.push('555 RCPT TO parameters not recognized or not implemented')
537531
return
538-
if not address:
539-
self.push('501 Syntax: RCPT TO: <address>')
540-
return
541532
self.rcpttos.append(address)
542533
print('recips:', self.rcpttos, file=DEBUGSTREAM)
543534
self.push('250 OK')

0 commit comments

Comments
 (0)