mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-08-31 19:27:18 +00:00
(fix) fixed forwarding mails with attachments containing slashes in file names
This commit is contained in:
@@ -1158,7 +1158,14 @@ static NSString *userAgent = nil;
|
||||
name = [name substringFromIndex: r.location + 1];
|
||||
|
||||
if (![self isValidAttachmentName: name])
|
||||
return [self invalidAttachmentNameError: name];
|
||||
{
|
||||
if ([name rangeOfString: @"/"].length)
|
||||
{
|
||||
name = [name stringByReplacingOccurrencesOfString: @"/" withString: @"-"];
|
||||
}
|
||||
else
|
||||
return [self invalidAttachmentNameError: name];
|
||||
}
|
||||
|
||||
p = [self pathToAttachmentWithName: name];
|
||||
if (![_attach writeToFile: p atomically: YES])
|
||||
|
||||
Reference in New Issue
Block a user