core/src/commands.cpp
changeset 69 5b2eab065888
parent 67 683f4b1f08ce
child 68 377ac716dabb
equal deleted inserted replaced
65:31c9a831b704 69:5b2eab065888
  5258 	LeaveIfErr(aPcons.Create(IoSession(), *iName, *iName), _L("Could not create persistent console '%S'"), iName);
  5258 	LeaveIfErr(aPcons.Create(IoSession(), *iName, *iName), _L("Could not create persistent console '%S'"), iName);
  5259 
  5259 
  5260 	RChildProcess proc;
  5260 	RChildProcess proc;
  5261 	TRAPL(proc.CreateL(command, args, IoSession(), aPcons, &Env()), _L("Could not create process %S"), &command);
  5261 	TRAPL(proc.CreateL(command, args, IoSession(), aPcons, &Env()), _L("Could not create process %S"), &command);
  5262 	
  5262 	
       
  5263 	// Wait for process to rendezvous before returning to close aPcons - we have to give the child time to connect to the console.
       
  5264 	TRequestStatus status;
       
  5265 	proc.Process().Rendezvous(status);
  5263 	proc.Detach();
  5266 	proc.Detach();
       
  5267 	User::WaitForRequest(status);
  5264 	proc.Close();
  5268 	proc.Close();
  5265 	}
  5269 	}
  5266 	
  5270 	
  5267 TInt CCmdPcons::DoAttach(RIoPersistentConsole& aPcons, RIoConsole& aNew, RIoPersistentConsole::TCloseBehaviour aOnClose)
  5271 TInt CCmdPcons::DoAttach(RIoPersistentConsole& aPcons, RIoConsole& aNew, RIoPersistentConsole::TCloseBehaviour aOnClose)
  5268 	{
  5272 	{