Skip to content

Commit aac399b

Browse files
committed
Correct the poplib example. Stephan Richter pointed out some problems
with it.
1 parent b057dd8 commit aac399b

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

Doc/lib/libpoplib.tex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -119,15 +119,15 @@ \subsection{POP3 Example}
119119
mailbox and retrieves and prints all messages:
120120

121121
\begin{verbatim}
122-
import getpass, poplib, string
122+
import getpass, poplib
123123
124124
M = poplib.POP3('localhost')
125125
M.user(getpass.getuser())
126-
M.pass(getpass.getpass())
126+
M.pass_(getpass.getpass())
127127
numMessages = len(M.list()[1])
128128
for i in range(numMessages):
129129
for j in M.retr(i+1)[1]:
130-
sys.stdout.write(j)
130+
print j
131131
\end{verbatim}
132132

133133
At the end of the module, there is a test section that contains a more

0 commit comments

Comments
 (0)