Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
14f39402
Kaydet (Commit)
14f39402
authored
Agu 31, 2005
tarafından
Piers Lauder
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
changed select() so readonly flag is treated as a boolean
üst
a47d1c08
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
imaplib.py
Lib/imaplib.py
+4
-4
No files found.
Lib/imaplib.py
Dosyayı görüntüle @
14f39402
...
@@ -155,7 +155,7 @@ class IMAP4:
...
@@ -155,7 +155,7 @@ class IMAP4:
self
.
tagged_commands
=
{}
# Tagged commands awaiting response
self
.
tagged_commands
=
{}
# Tagged commands awaiting response
self
.
untagged_responses
=
{}
# {typ: [data, ...], ...}
self
.
untagged_responses
=
{}
# {typ: [data, ...], ...}
self
.
continuation_response
=
''
# Last continuation response
self
.
continuation_response
=
''
# Last continuation response
self
.
is_readonly
=
None
# READ-ONLY desired state
self
.
is_readonly
=
False
# READ-ONLY desired state
self
.
tagnum
=
0
self
.
tagnum
=
0
# Open socket to server.
# Open socket to server.
...
@@ -622,12 +622,12 @@ class IMAP4:
...
@@ -622,12 +622,12 @@ class IMAP4:
return
self
.
_untagged_response
(
typ
,
dat
,
name
)
return
self
.
_untagged_response
(
typ
,
dat
,
name
)
def
select
(
self
,
mailbox
=
'INBOX'
,
readonly
=
Non
e
):
def
select
(
self
,
mailbox
=
'INBOX'
,
readonly
=
Fals
e
):
"""Select a mailbox.
"""Select a mailbox.
Flush all untagged responses.
Flush all untagged responses.
(typ, [data]) = <instance>.select(mailbox='INBOX', readonly=
Non
e)
(typ, [data]) = <instance>.select(mailbox='INBOX', readonly=
Fals
e)
'data' is count of messages in mailbox ('EXISTS' response).
'data' is count of messages in mailbox ('EXISTS' response).
...
@@ -636,7 +636,7 @@ class IMAP4:
...
@@ -636,7 +636,7 @@ class IMAP4:
"""
"""
self
.
untagged_responses
=
{}
# Flush old responses.
self
.
untagged_responses
=
{}
# Flush old responses.
self
.
is_readonly
=
readonly
self
.
is_readonly
=
readonly
if
readonly
is
not
None
:
if
readonly
:
name
=
'EXAMINE'
name
=
'EXAMINE'
else
:
else
:
name
=
'SELECT'
name
=
'SELECT'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment