diff options
| author | Kenichi Handa | 2003-09-08 11:56:09 +0000 |
|---|---|---|
| committer | Kenichi Handa | 2003-09-08 11:56:09 +0000 |
| commit | 463f5630a5e7cbe7f042bc1175d1fa1c4e98860f (patch) | |
| tree | 3287d0c628fea2249abf4635b3a4f45bedd6f8c4 /src/w32.c | |
| parent | 4256310de631bd57c78b88b5131caa073315b3d7 (diff) | |
| download | emacs-463f5630a5e7cbe7f042bc1175d1fa1c4e98860f.tar.gz emacs-463f5630a5e7cbe7f042bc1175d1fa1c4e98860f.zip | |
New directory
Diffstat (limited to 'src/w32.c')
| -rw-r--r-- | src/w32.c | 22 |
1 files changed, 4 insertions, 18 deletions
| @@ -3450,22 +3450,11 @@ sys_pipe (int * phandles) | |||
| 3450 | 3450 | ||
| 3451 | if (rc == 0) | 3451 | if (rc == 0) |
| 3452 | { | 3452 | { |
| 3453 | /* Protect against overflow, since Windows can open more handles than | 3453 | flags = FILE_PIPE | FILE_READ | FILE_BINARY; |
| 3454 | our fd_info array has room for. */ | 3454 | fd_info[phandles[0]].flags = flags; |
| 3455 | if (phandles[0] >= MAXDESC || phandles[1] >= MAXDESC) | ||
| 3456 | { | ||
| 3457 | _close (phandles[0]); | ||
| 3458 | _close (phandles[1]); | ||
| 3459 | rc = -1; | ||
| 3460 | } | ||
| 3461 | else | ||
| 3462 | { | ||
| 3463 | flags = FILE_PIPE | FILE_READ | FILE_BINARY; | ||
| 3464 | fd_info[phandles[0]].flags = flags; | ||
| 3465 | 3455 | ||
| 3466 | flags = FILE_PIPE | FILE_WRITE | FILE_BINARY; | 3456 | flags = FILE_PIPE | FILE_WRITE | FILE_BINARY; |
| 3467 | fd_info[phandles[1]].flags = flags; | 3457 | fd_info[phandles[1]].flags = flags; |
| 3468 | } | ||
| 3469 | } | 3458 | } |
| 3470 | 3459 | ||
| 3471 | return rc; | 3460 | return rc; |
| @@ -3966,6 +3955,3 @@ void globals_of_w32 () | |||
| 3966 | } | 3955 | } |
| 3967 | 3956 | ||
| 3968 | /* end of nt.c */ | 3957 | /* end of nt.c */ |
| 3969 | |||
| 3970 | /* arch-tag: 90442dd3-37be-482b-b272-ac752e3049f1 | ||
| 3971 | (do not change this comment) */ | ||