title: NSTask pipes output to Console rather than the NSFileHandle
body: <p>I set up an NSNotification for <code>NSFileHandleReadCompletionNotification</code>.</p>
  
  <p>I set up the standard I/O with two separate pipes.</p>
  
  <pre><code>NSPipe * input  = NSPipe.new;
  NSPipe * output = NSPipe.new;
  
  [serverTask setStandardInput:input];
  [serverTask setStandardOutput:output];
  </code></pre>
  
  <p>I launch a NSTask executing a Java jar, and start reading the data.</p>
  
  <p><code>[[serverTask.standardOutput fileHandleForReading] readInBackgroundAndNotify];</code></p>
  
  <p>and I continuously read the data and append the data in an <code>NSTextView</code> if it is new data:</p>
  
  <pre><code>- (void)serverLogHasChanged:(NSNotification *)notification
  {
      [[serverTask.standardOutput fileHandleForReading] readInBackgroundAndNotify];
  
      NSData * newData = [notification.userInfo objectForKey:NSFileHandleNotificationDataItem];
  
      if (newData != nil &amp;&amp; availableData != newData)
      {
          NSMutableString * serverLogString = [NSMutableString stringWithString:serverLog.string];
  
          [serverLogString appendString:[NSString.alloc initWithData:newData encoding:NSUTF8StringEncoding]];
          [serverLog setString:serverLogString];
          [serverLog.enclosingScrollView.contentView scrollPoint:NSMakePoint(0, NSMaxY(serverLog.enclosingScrollView.contentView.bounds))];
      }
  
      newData = availableData;
  }
  </code></pre>
  
  <p>However, I'm getting strange output into the <code>NSTextView</code> </p>
  
  <p><img src="https://i.stack.imgur.com/KMj2A.png" alt="enter image description here"></p>
  
  <p>Those ">" characters should be lines of actual output, but instead the output ends up in Xcode's console.</p>
  
  <p>In other words, the console is printing out the output instead of my <code>NSPipe</code> which is printing out only the indication of new lines of the output.</p>