From: Guido van Rossum Date: Wed, 2 Sep 1998 14:42:02 +0000 (+0000) Subject: Fix suggested by movits@lockstar.com (plus doc string by myself) X-Git-Tag: v1.5.2a2~326 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f6ae743cb53a2953c7fb063963ec48029206c8b0;p=thirdparty%2FPython%2Fcpython.git Fix suggested by movits@lockstar.com (plus doc string by myself) for LIST command with msg argument. --- diff --git a/Lib/poplib.py b/Lib/poplib.py index 2539892e64a6..0f588c15f10d 100644 --- a/Lib/poplib.py +++ b/Lib/poplib.py @@ -196,14 +196,17 @@ class POP3: return (numMessages, sizeMessages) - def list(self, which=None): + def list(self, msg=None): """Request listing, return result. - Result is in form ['response', ['mesg_num octets', ...]]. - Unsure what the optional 'msg' arg does. + Result without a msg argument is in form + ['response', ['mesg_num octets', ...]]. + + Result when a msg argument is given is a single response: + the "scan listing" for that message. """ if which: - return self._longcmd('LIST %s' % which) + return self._shortcmd('LIST %s' % which) return self._longcmd('LIST')