aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Andree <matthias.andree@gmx.de>2005-06-11 20:09:06 +0000
committerMatthias Andree <matthias.andree@gmx.de>2005-06-11 20:09:06 +0000
commit80857e61ed3a9ea304174426518ad707692fde82 (patch)
tree6da67bcdeb4009b0b91248c01b35e688e35d24ed
parentda2fa1ccbe7d416db1ebe69710b31c335df23d2f (diff)
downloadfetchmail-80857e61ed3a9ea304174426518ad707692fde82.tar.gz
fetchmail-80857e61ed3a9ea304174426518ad707692fde82.tar.bz2
fetchmail-80857e61ed3a9ea304174426518ad707692fde82.zip
Miroslav Trmac writes:
The 'port' setting used to be an integer, now it can be an integer or a string, depending on the presence of IPv6 support. fetchmailconf assumes 'port' is an integer, though. When 'port' is a string, it defaults to None; fetchmailconf can't handle that and writes 'port None' to the output config file if the server entry is not edited, see https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=55623 The attached patch fixes this. Note that fetchmailconf still doesn't support other string values for 'port', even with this patch. Mirek svn path=/trunk/; revision=4058
-rw-r--r--NEWS3
-rwxr-xr-xfetchmailconf2
2 files changed, 4 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index 2ae334d3..d60cbfe2 100644
--- a/NEWS
+++ b/NEWS
@@ -65,6 +65,9 @@
manual page. UIDL isn't flaky as the man page suggested, but a
reliability feature. In fact, IMAP4 code is flaky in that it relies on
the upstream seen flags. (Matthias Andree)
+* Miloslav Trmac's patch for fetchmailconf to support string-type values
+ of the "port" variable, avoiding "port None" corruption in .fetchmailrc.
+ To fix Redhat Bug #55623 (Matthias Andree)
fetchmail-6.2.5 (Wed Oct 15 18:39:22 EDT 2003), 23079 lines:
diff --git a/fetchmailconf b/fetchmailconf
index ef41a5df..b28a5d96 100755
--- a/fetchmailconf
+++ b/fetchmailconf
@@ -133,7 +133,7 @@ class Server:
res = res + (" via " + str(self.via) + "\n");
if self.protocol != ServerDefaults.protocol:
res = res + " with proto " + self.protocol
- if self.port != defaultports[self.protocol] and self.port != 0:
+ if self.port != defaultports[self.protocol] and self.port:
res = res + " port " + `self.port`
if self.timeout != ServerDefaults.timeout:
res = res + " timeout " + `self.timeout`