/* Nothing below here GCs so our string pointers shouldn't move. */
new_argv = alloca_array (char *, nargv + 2);
- new_argv[0] = (char *) XSTRING_DATA (program);
+ GET_C_STRING_FILENAME_DATA_ALLOCA (program, new_argv[0]);
for (i = 0; i < nargv; i++)
{
Lisp_Object tem = argv[i];
new_argv[i + 1] = (char *) XSTRING_DATA (tem);
}
new_argv[i + 1] = 0;
- current_dir = (char *) XSTRING_DATA (cur_dir);
+ GET_C_STRING_FILENAME_DATA_ALLOCA (cur_dir, current_dir);
#ifdef HAVE_PTYS
if (!NILP (Vprocess_connection_type))
else
{ /* We got here from a longjmp() from the SIGPIPE handler */
signal (SIGPIPE, old_sigpipe);
+ /* Close the file lstream so we don't attempt to write to it further */
+ /* #### There is controversy over whether this might cause fd leakage */
+ /* my tests say no. -slb */
+ XLSTREAM (p->pipe_outstream)->flags &= ~LSTREAM_FL_IS_OPEN;
p->status_symbol = Qexit;
p->exit_code = 256; /* #### SIGPIPE ??? */
p->core_dumped = 0;