/* Create MI console channels, each with a different prefix so they
can be distinguished. */
- mi->out = mi_console_file_new (mi->raw_stdout, "~", '"');
- mi->err = mi_console_file_new (mi->raw_stdout, "&", '"');
+ mi->out = new mi_console_file (mi->raw_stdout, "~", '"');
+ mi->err = new mi_console_file (mi->raw_stdout, "&", '"');
mi->log = mi->err;
- mi->targ = mi_console_file_new (mi->raw_stdout, "@", '"');
- mi->event_channel = mi_console_file_new (mi->raw_stdout, "=", 0);
+ mi->targ = new mi_console_file (mi->raw_stdout, "@", '"');
+ mi->event_channel = new mi_console_file (mi->raw_stdout, "=", 0);
name = interp_name (interp);
/* INTERP_MI selects the most recent released version. "mi2" was
it), and create one based on raw_stdout instead. */
if (logfile)
{
- ui_file_delete (out);
- out = tee_file_new (mi->raw_stdout, 0, logfile, 0);
+ delete out;
+ out = new tee_file (mi->raw_stdout, false, logfile, false);
}
mi->saved_raw_stdout = mi->raw_stdout;
mi->saved_raw_stdout = NULL;
}
- mi_console_set_raw (mi->out, mi->raw_stdout);
- mi_console_set_raw (mi->err, mi->raw_stdout);
- mi_console_set_raw (mi->log, mi->raw_stdout);
- mi_console_set_raw (mi->targ, mi->raw_stdout);
- mi_console_set_raw (mi->event_channel, mi->raw_stdout);
+ mi->out->set_raw (mi->raw_stdout);
+ mi->err->set_raw (mi->raw_stdout);
+ mi->log->set_raw (mi->raw_stdout);
+ mi->targ->set_raw (mi->raw_stdout);
+ mi->event_channel->set_raw (mi->raw_stdout);
return 1;
}