Mercurial > emacs
changeset 25129:4f3c8f1cec96
(create_process): Detect failure of `pipe'.
author | Karl Heuer <kwzh@gnu.org> |
---|---|
date | Fri, 30 Jul 1999 14:39:27 +0000 |
parents | 2563b35e613f |
children | 3f2b516f9ddc |
files | src/process.c |
diffstat | 1 files changed, 11 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/process.c Fri Jul 30 14:37:30 1999 +0000 +++ b/src/process.c Fri Jul 30 14:39:27 1999 +0000 @@ -1379,10 +1379,19 @@ } #else /* not SKTPAIR */ { - pipe (sv); + int tem; + tem = pipe (sv); + if (tem < 0) + report_file_error ("Creating pipe", Qnil); inchannel = sv[0]; forkout = sv[1]; - pipe (sv); + tem = pipe (sv); + if (tem < 0) + { + close (inchannel); + close (forkout); + report_file_error ("Creating pipe", Qnil); + } outchannel = sv[1]; forkin = sv[0]; }