X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/22f3361e1cf25c52a2da8fdfc5cb081809e18fb9..01f5f03e7f9c19ca75ae6dbd4050c2b54e52e406:/src/msw/utilsexc.cpp diff --git a/src/msw/utilsexc.cpp b/src/msw/utilsexc.cpp index 28fc5edfed..17eac58b19 100644 --- a/src/msw/utilsexc.cpp +++ b/src/msw/utilsexc.cpp @@ -6,7 +6,7 @@ // Created: 04/01/98 // RCS-ID: $Id$ // Copyright: (c) 1998-2002 wxWindows dev team -// Licence: wxWindows license +// Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// // ============================================================================ @@ -47,7 +47,7 @@ #include -#if !defined(__GNUWIN32__) && !defined(__WXWINE__) && !defined(__SALFORDC__) && !defined(__WXMICROWIN__) +#if !defined(__GNUWIN32__) && !defined(__SALFORDC__) && !defined(__WXMICROWIN__) #include #ifndef __MWERKS__ #include @@ -59,8 +59,10 @@ #include #endif -#if defined(__WIN32__) && !defined(__WXWINE__) && !defined(__WXMICROWIN__) -#include +#if defined(__WIN32__) && !defined(__WXMICROWIN__) +#ifndef __UNIX__ + #include +#endif #ifndef __GNUWIN32__ #include @@ -347,10 +349,6 @@ wxPipeInputStream::~wxPipeInputStream() bool wxPipeInputStream::CanRead() const { - // FIXME -#ifdef __WXWINE__ - return FALSE; -#else // !Wine if ( !IsOpened() ) return FALSE; @@ -387,7 +385,6 @@ bool wxPipeInputStream::CanRead() const } return nAvailable != 0; -#endif // Wine/!Wine } size_t wxPipeInputStream::OnSysRead(void *buffer, size_t len) @@ -495,6 +492,14 @@ long wxExecute(const wxString& cmd, int flags, wxProcess *handler) { wxCHECK_MSG( !!cmd, 0, wxT("empty command in wxExecute") ); +#if wxUSE_THREADS + // for many reasons, the code below breaks down if it's called from another + // thread -- this could be fixed, but as Unix versions don't support this + // neither I don't want to waste time on this now + wxASSERT_MSG( wxThread::IsMain(), + _T("wxExecute() can be called only from the main thread") ); +#endif // wxUSE_THREADS + wxString command; #if wxUSE_IPC