project_files/HedgewarsMobile/Classes/EngineProtocolNetwork.m
changeset 6083 72c882c0fd0f
parent 6078 8c0cc07731e5
child 6084 e692c0348e74
--- a/project_files/HedgewarsMobile/Classes/EngineProtocolNetwork.m	Tue Oct 04 17:13:39 2011 -0400
+++ b/project_files/HedgewarsMobile/Classes/EngineProtocolNetwork.m	Wed Oct 05 00:18:54 2011 +0200
@@ -61,7 +61,7 @@
 #pragma mark -
 #pragma mark Spawner functions
 -(void) spawnThread:(NSString *)onSaveFile withOptions:(NSDictionary *)dictionary {
-    self.stream = [[NSOutputStream alloc] initToFileAtPath:onSaveFile append:YES];
+    self.stream = (onSaveFile) ? [[NSOutputStream alloc] initToFileAtPath:onSaveFile append:YES] : nil;
     [self.stream open];
 
     [NSThread detachNewThreadSelector:@selector(engineProtocol:)