From a329d031aac349c0ad2b0768cc24ce69dc09a577 Mon Sep 17 00:00:00 2001 From: rowanbeentje Date: Sat, 24 Apr 2010 01:36:34 +0000 Subject: Merge in a number of fixes from trunk (r2065, r2066, r2067, r2068, r2069, r2074, r2075, r2076, r2078, r2079, r2081, r2083, r2084, r2085, r2089, r2090, r2100, r2110, r2117, r2118, r2119, r2120, r2128, r2132, r2133, r2134, r2137, r2138, r2139, r2140, r2142, r2150, r2152, r2153, r2154, r2155, r2158, and r2160) --- Source/SPQueryController.m | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'Source/SPQueryController.m') diff --git a/Source/SPQueryController.m b/Source/SPQueryController.m index d34655e7..b6a64636 100644 --- a/Source/SPQueryController.m +++ b/Source/SPQueryController.m @@ -777,7 +777,8 @@ static SPQueryController *sharedQueryController = nil; - (void)dealloc { messagesVisibleSet = nil; - + [NSObject cancelPreviousPerformRequestsWithTarget:self]; + [dateFormatter release], dateFormatter = nil; [messagesFullSet release], messagesFullSet = nil; @@ -941,8 +942,15 @@ static SPQueryController *sharedQueryController = nil; */ - (void)_addMessageToConsole:(NSString *)message connection:(NSString *)connection isError:(BOOL)error { - SPConsoleMessage *consoleMessage = [SPConsoleMessage consoleMessageWithMessage:[[[message stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]] stringByReplacingOccurrencesOfString:@"\n" withString:@" "] stringByAppendingString:@";"] date:[NSDate date] connection:connection]; - + NSString *messageTemp = [[message stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]] stringByReplacingOccurrencesOfString:@"\n" withString:@" "]; + + // Only append a semi-colon (;) if the supplied message is not an error + if (!error) { + messageTemp = [messageTemp stringByAppendingString:@";"]; + } + + SPConsoleMessage *consoleMessage = [SPConsoleMessage consoleMessageWithMessage:messageTemp date:[NSDate date] connection:connection]; + [consoleMessage setIsError:error]; [messagesFullSet addObject:consoleMessage]; -- cgit v1.2.3