]> git.saurik.com Git - wxWidgets.git/blobdiff - src/unix/utilsunx.cpp
removed assert which could be provoked by correct code
[wxWidgets.git] / src / unix / utilsunx.cpp
index 23658ace65510ea4c523412dab259f6b4960474e..ad8a078fabd6c6d96e2bf1a4e514748e168e4634 100644 (file)
@@ -333,6 +333,8 @@ void wxHandleProcessTermination(wxEndProcessData *proc_data)
 // wxStream classes to support IO redirection in wxExecute
 // ----------------------------------------------------------------------------
 
+#if wxUSE_STREAMS
+
 class wxProcessFileInputStream : public wxInputStream
 {
 public:
@@ -429,6 +431,8 @@ size_t wxProcessFileOutputStream::OnSysWrite(const void *buffer, size_t bufsize)
     return ret;
 }
 
+#endif // wxUSE_STREAMS
+
 long wxExecute(wxChar **argv,
                bool sync,
                wxProcess *process)
@@ -590,19 +594,21 @@ long wxExecute(wxChar **argv,
         // pipe initialization: construction of the wxStreams
         if ( process && process->IsRedirected() )
         {
+#if wxUSE_STREAMS
             // These two streams are relative to this process.
             wxOutputStream *outStream = new wxProcessFileOutputStream(pipeIn[1]);
             wxInputStream *inStream = new wxProcessFileInputStream(pipeOut[0]);
             wxInputStream *errStream = new wxProcessFileInputStream(pipeErr[0]);
 
+            process->SetPipeStreams(inStream, outStream, errStream);
+#endif // wxUSE_STREAMS
+
             close(pipeIn[0]); // close reading side
             close(pipeOut[1]); // close writing side
             close(pipeErr[1]); // close writing side
-
-            process->SetPipeStreams(inStream, outStream, errStream);
         }
 
-#if wxUSE_GUI
+#if wxUSE_GUI && !defined(__WXMICROWIN__)
         wxEndProcessData *data = new wxEndProcessData;
 
         if ( sync )