bool wxColourDisplay(void)
{
- wxFAIL_MSG( "wxColourDisplay always returns TRUE" );
return TRUE;
}
vfprintf( stderr, format, ap );
fflush( stderr );
va_end(ap);
-};
+}
void wxError( const wxString &msg, const wxString &title )
{
if (!title.IsNull()) fprintf( stderr, "%s ", WXSTRINGCAST(title) );
if (!msg.IsNull()) fprintf( stderr, ": %s", WXSTRINGCAST(msg) );
fprintf( stderr, ".\n" );
-};
+}
void wxFatalError( const wxString &msg, const wxString &title )
{
if (!msg.IsNull()) fprintf( stderr, ": %s", WXSTRINGCAST(msg) );
fprintf( stderr, ".\n" );
exit(3); // the same exit code as for abort()
-};
+}
//------------------------------------------------------------------------
// directory routines
strcpy( buf, WXSTRINGCAST(dir) );
struct stat sbuf;
return ((stat(buf, &sbuf) != -1) && S_ISDIR(sbuf.st_mode) ? TRUE : FALSE);
-};
+}
//------------------------------------------------------------------------
// subprocess routines
delete proc_data;
else
proc_data->pid = 0;
-};
+}
long wxExecute( char **argv, bool sync, wxProcess *process )
{
else if (pid == 0) {
// we're in child
close(end_proc_detect[0]); // close reading side
+ // These three lines close the open file descriptors to
+ // to avoid any input/output which might block the process
+ // or irritate the user. If one wants proper IO for the sub-
+ // process, the "right thing to do" is to start an xterm executing
+ // it.
+ close(STDIN_FILENO);
+ close(STDOUT_FILENO);
+ close(STDERR_FILENO);
#ifdef _AIX
execvp ((const char *)*argv, (const char **)argv);
// failed!
return pid;
}
-};
+}
long wxExecute( const wxString& command, bool sync, wxProcess *process )
{
delete [] tmp;
return lRc;
-};
+}