pull/12/head
Ludovic Marcotte 2013-07-18 11:46:49 -04:00
parent b85ed0db1c
commit 256b679798
2 changed files with 18 additions and 1 deletions

3
NEWS
View File

@ -4,9 +4,10 @@
New features
- print gridlines of calendar in 15-minute intervals
- allow the events/tasks lists to be collapsable
Enhancements
- bubble box of events no longer overlaps the current event
- now pass the x-originating-ip using the IMAP ID extension
Bug fixes
- properly handle RFC2231 everywhere

View File

@ -151,6 +151,22 @@ static BOOL debugOn = YES;
newConnection = (NGImap4Connection *) [NSNull null];
[self errorWithFormat:@"Could not connect IMAP4"];
}
else
{
// If the server has the ID capability (RFC 2971), we set the x-originating-ip
// accordingly for the IMAP connection.
NSString *remoteHost;
remoteHost = [[context request] headerForKey: @"x-webobjects-remote-host"];
if (remoteHost)
{
if ([[[[newConnection client] capability] objectForKey: @"capability"] containsObject: @"id"])
{
[[newConnection client] processCommand: [NSString stringWithFormat: @"ID (\"x-originating-ip\" \"%@\")", remoteHost]];
}
}
}
return newConnection;
}