diff options
-rw-r--r-- | macosx/HBOutputRedirect.m | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/macosx/HBOutputRedirect.m b/macosx/HBOutputRedirect.m index 7239fe3cd..a4415792a 100644 --- a/macosx/HBOutputRedirect.m +++ b/macosx/HBOutputRedirect.m @@ -185,7 +185,10 @@ int stderrwrite(void *inFD, const char *buffer, int size) - (void)forwardOutput:(NSData *)data { NSString *string = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; - [listeners makeObjectsPerformSelector:forwardingSelector withObject:string]; + if (string) + { + [listeners makeObjectsPerformSelector:forwardingSelector withObject:string]; + } [string release]; } |