Skip to content

Commit

Permalink
Fix non-literal NSString format specifiers.
Browse files Browse the repository at this point in the history
Trying to get things to compile on clang 4.

It seems like there was an unnecessary level of indirection on these,
but that may have been intentional. Will ask.
  • Loading branch information
Shadowfiend committed Jul 12, 2012
1 parent 5ea6228 commit f949eb3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/ViBundle.m
Original file line number Diff line number Diff line change
Expand Up @@ -304,8 +304,8 @@ + (void)setupEnvironment:(NSMutableDictionary *)env

NSMutableString *urls = [NSMutableString string];
for (url in selectedURLs) {
[urls appendFormat:[NSString stringWithFormat:@"'%@' ",
[[url absoluteString] stringByReplacingOccurrencesOfString:@"'" withString:@"'\\''"]]];
[urls appendFormat:@"'%@' ",
[[url absoluteString] stringByReplacingOccurrencesOfString:@"'" withString:@"'\\''"]];
}
[env setObject:[urls stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]] forKey:@"TM_SELECTED_URLS"];

Expand All @@ -316,8 +316,8 @@ + (void)setupEnvironment:(NSMutableDictionary *)env
if ([url isFileURL]) {
NSMutableString *paths = [NSMutableString string];
for (url in selectedURLs) {
[paths appendFormat:[NSString stringWithFormat:@"'%@' ",
[[url path] stringByReplacingOccurrencesOfString:@"'" withString:@"'\\''"]]];
[paths appendFormat:@"'%@' ",
[[url path] stringByReplacingOccurrencesOfString:@"'" withString:@"'\\''"]];
}
[env setObject:[paths stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]] forKey:@"TM_SELECTED_FILES"];

Expand Down

0 comments on commit f949eb3

Please sign in to comment.