Changeset 2920
- Timestamp:
- Dec 29, 2006, 4:41:12 PM (19 years ago)
- Location:
- trunk/libc
- Files:
-
- 5 added
- 5 deleted
- 8 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/libc/include/klibc/backend.h
r2918 r2920 465 465 int __libc_Back_fsUnlink(const char *pszPath); 466 466 467 /** 468 * Sets the umask to mask & 0777. 469 * 470 * The umask is used by open(), creat(), mkdir(), mkfifo(), 471 * mknod(), mq_open() and sem_open() to set the initial permissions 472 * for an newly created object. 473 * 474 * @returns The old umask. (Will never fail!) 475 * @param mask The new umask. 476 */ 477 mode_t __libc_Back_fsUMask(mode_t mask); 478 467 479 468 480 /** @defgroup __libc_Back_io LIBC Backend - I/O and File Management. … … 485 497 486 498 /** 499 * Creates an anonymous pipe. 500 * 501 * @returns 0 and *pfhRead and *pfhWrite on success. 502 * @returns Negated error code (errno.h) on failure. 503 * @param pfhRead Where to store the read end handle. 504 * @param pfhWrite Where to store the write end handle. 505 * @param cbSuggestion The suggested buffer size. 0 means default. 506 * @param fBinaryText 0=text; 1=binary. 507 */ 508 int __libc_Back_ioPipe(int *pfhRead, int *pfhWrite, size_t cbSuggestion, int fBinaryText); 509 510 /** 487 511 * Closes a file handle. 488 512 * … … 542 566 */ 543 567 int __libc_Back_ioFileSizeSet(int fh, __off_t cbFile, int fZero); 568 569 /** 570 * Execute all pending I/O operations and flush buffers associated with a file handle. 571 * 572 * @returns 0 on success. 573 * @returns Negated errno on failure. 574 * @param fh The file handle. 575 */ 576 int __libc_Back_ioSync(int fh); 577 578 /** 579 * Duplicate handle. 580 * 581 * @returns 0 on success. 582 * @returns Negated errno on failure. 583 * @param fh The file handle to duplicate. 584 * @param pfhNew Where to store the duplicate filehandle. 585 * The input value describe how the handle is to be 586 * duplicated. If it's -1 a new handle is allocated. 587 * Any other value will result in that value to be 588 * used as handle. Any existing handle with that 589 * value will be closed. 590 * @param fClose Whether or not to close *pfhNew. 591 */ 592 int __libc_Back_ioDuplicate(int fh, int *pfhNew, int fClose); 544 593 545 594 /** -
trunk/libc/include/klibc/io.h
r2909 r2920 86 86 { 87 87 /** Handle type. */ 88 __LIBC_FHTYPE enmType; 89 /** Close operation. 88 __LIBC_FHTYPE enmType; 89 90 /** 91 * Close operation. 92 * 90 93 * @returns 0 on success. 91 94 * @returns Negated errno on failure. … … 93 96 */ 94 97 int (*pfnClose)(struct __libc_FileHandle *pFH); 95 /** Read operation. 98 99 /** 100 * Read operation. 101 * 96 102 * @returns 0 on success. 97 103 * @returns Negated errno on failure. … … 102 108 */ 103 109 int (*pfnRead)(struct __libc_FileHandle *pFH, void *pvBuf, size_t cbRead, size_t *pcbRead); 104 /** Write operation. 110 111 /** 112 * Write operation. 113 * 105 114 * @returns 0 on success. 106 115 * @returns Negated errno on failure. … … 111 120 */ 112 121 int (*pfnWrite)(struct __libc_FileHandle *pFH, const void *pvBuf, size_t cbWrite, size_t *pcbWritten); 113 /** Seek operation. 122 123 /** 124 * Seek operation. 125 * 114 126 * @returns 0 on success. 115 127 * @returns Negated errno on failure. … … 120 132 */ 121 133 int (*pfnSeek)(struct __libc_FileHandle *pFH, off_t off, int iMethod, off_t *poffActual); 134 122 135 /** 123 136 * Sets the size of an open file. … … 130 143 */ 131 144 int (*pfnSizeSet)(struct __libc_FileHandle *pFH, off_t cbFile, int fZero); 132 /** Duplicate handle operation. 145 146 /** 147 * Execute all pending I/O operations and flush buffers associated with a file handle. 148 * 149 * @returns 0 on success. 150 * @returns Negative error code (errno.h) on failure. 151 * @param pFH The file handle structure. 152 */ 153 int (*pfnSync)(struct __libc_FileHandle *pFH); 154 155 /** 156 * Duplicate handle operation. 157 * 133 158 * @returns 0 on success. 134 159 * @returns Negated errno on failure. … … 142 167 */ 143 168 int (*pfnDuplicate)(struct __libc_FileHandle *pFH, int *pfhNew); 144 /** File Control operation. 169 170 /** 171 * File Control operation. 172 * 145 173 * @returns 0 on success. 146 174 * @returns Negated errno on failure. … … 153 181 */ 154 182 int (*pfnFileControl)(struct __libc_FileHandle *pFH, int iRequest, int iArg, int *prc); 155 /** I/O Control operation. 183 184 /** 185 * I/O Control operation. 186 * 156 187 * @returns 0 on success. 157 188 * @returns Negated errno on failure. … … 164 195 */ 165 196 int (*pfnIOControl)(struct __libc_FileHandle *pFH, int iIOControl, int iArg, int *prc); 166 /** Select operation. 197 198 /** 199 * Select operation. 200 * 167 201 * The select operation is only performed if all handles have the same 168 202 * select routine (the main worker checks this). … … 179 213 */ 180 214 int (*pfnSelect)(int cFHs, struct fd_set *pRead, struct fd_set *pWrite, struct fd_set *pExcept, struct timeval *tv, int *prc); 181 /** Fork notification - parent context. 215 216 /** 217 * Fork notification - parent context. 218 * 182 219 * If NULL it's assumed that no notifiction is needed. 183 220 * … … 189 226 */ 190 227 int (*pfnForkParent)(struct __libc_FileHandle *pFH, __LIBC_PFORKHANDLE pForkHandle, __LIBC_FORKOP enmOperation); 191 /** Fork notification - child context. 228 229 /** 230 * Fork notification - child context. 231 * 192 232 * Only the __LIBC_FORK_OP_FORK_CHILD operation is forwarded atm. 193 233 * If NULL it's assumed that no notifiction is needed. -
trunk/libc/src/kNIX/Makefile.kmk
r2918 r2920 46 46 $(PATH_LIBC_SRC)/kNIX/b_fsSymlinkStat.c \ 47 47 $(PATH_LIBC_SRC)/kNIX/b_fsSymlinkTimesSet.c \ 48 $(PATH_LIBC_SRC)/kNIX/b_fsUMask.c \ 48 49 $(PATH_LIBC_SRC)/kNIX/b_ioClose.c \ 49 50 $(PATH_LIBC_SRC)/kNIX/b_ioDirGetEntries.c \ 51 $(PATH_LIBC_SRC)/kNIX/b_ioDuplicate.c \ 50 52 $(PATH_LIBC_SRC)/kNIX/b_ioFileSizeSet.c \ 51 53 $(PATH_LIBC_SRC)/kNIX/b_ioFHToPath.c \ 52 54 $(PATH_LIBC_SRC)/kNIX/b_ioRead.c \ 53 55 $(PATH_LIBC_SRC)/kNIX/b_ioSeek.c \ 56 $(PATH_LIBC_SRC)/kNIX/b_ioSync.c \ 54 57 $(PATH_LIBC_SRC)/kNIX/b_ioTTYName.c \ 55 58 $(PATH_LIBC_SRC)/kNIX/b_ioWrite.c \ … … 67 70 $(PATH_LIBC_SRC)/kNIX/_os_version.c \ 68 71 69 # $(PATH_LIBC_SRC)/kNIX/b_ioDuplicate.c \70 72 71 73 … … 92 94 $(PATH_LIBC_SRC)/kNIX/os2/b_ioFileControl.c \ 93 95 $(PATH_LIBC_SRC)/kNIX/os2/b_ioFileOpen.c \ 96 $(PATH_LIBC_SRC)/kNIX/os2/b_ioPipe.c \ 94 97 $(PATH_LIBC_SRC)/kNIX/os2/b_ldrClose.c \ 95 98 $(PATH_LIBC_SRC)/kNIX/os2/b_ldrExeName.c \ … … 144 147 $(PATH_LIBC_SRC)/kNIX/os2/fhOS2File.c \ 145 148 $(PATH_LIBC_SRC)/kNIX/os2/fs-os2.c \ 146 $(PATH_LIBC_SRC)/kNIX/os2/fsync.c \147 149 $(PATH_LIBC_SRC)/kNIX/os2/heaphigh.c \ 148 150 $(PATH_LIBC_SRC)/kNIX/os2/hooks.c \ … … 168 170 $(PATH_LIBC_SRC)/kNIX/os2/386/unwind.s \ 169 171 $(PATH_LIBC_SRC)/kNIX/os2/386/__init_environ.s \ 170 $(PATH_LIBC_SRC)/kNIX/os2/umask.c \171 $(PATH_LIBC_SRC)/kNIX/os2/__chmod.c \172 172 $(PATH_LIBC_SRC)/kNIX/os2/__spawnve.c \ 173 173 $(PATH_LIBC_SRC)/kNIX/os2/__read_kbd.c … … 175 175 $(PATH_LIBC_SRC)/kNIX/os2/__init.c \ 176 176 $(PATH_LIBC_SRC)/kNIX/os2/__initdll.c \ 177 $(PATH_LIBC_SRC)/kNIX/os2/__dup.c \178 $(PATH_LIBC_SRC)/kNIX/os2/__dup2.c \179 177 $(PATH_LIBC_SRC)/kNIX/os2/__ioctl1.c \ 180 178 $(PATH_LIBC_SRC)/kNIX/os2/__ioctl2.c \ 181 $(PATH_LIBC_SRC)/kNIX/os2/__pipe.c \182 179 $(PATH_LIBC_SRC)/kNIX/os2/__select.c \ 183 180 -
trunk/libc/src/kNIX/b_fsUMask.c
r2916 r2920 2 2 /** @file 3 3 * 4 * kNIX - umask .4 * kNIX - umask(). 5 5 * 6 * Copyright (c) 2004 knut st. osmundsen <bird-src-spam@innotek.de>6 * Copyright (c) 2004-2006 knut st. osmundsen <bird-src-spam@anduin.net> 7 7 * 8 8 * … … 25 25 */ 26 26 27 /*******************************************************************************28 * Header Files *29 *******************************************************************************/30 27 #include "kNIX.h" 31 #define __LIBC_LOG_GROUP __LIBC_LOG_GRP_BACK_ IO28 #define __LIBC_LOG_GROUP __LIBC_LOG_GRP_BACK_FS 32 29 #include <klibc/logstrict.h> 33 34 30 35 31 /** … … 43 39 * @param mask The new umask. 44 40 */ 45 mode_t _ STD(umask)(mode_t mask)41 mode_t __libc_Back_fsUMask(mode_t mask) 46 42 { 47 43 LIBCLOG_ENTER("mask=0%o\n", mask); -
trunk/libc/src/kNIX/os2/fhOS2File.c
r2914 r2920 67 67 if (!rc) 68 68 LIBCLOG_RETURN_INT(0); 69 rc = -__libc_ native2errno(rc);69 rc = -__libc_back_native2errno(rc); 70 70 LIBCLOG_ERROR_RETURN_INT(rc); 71 71 } … … 119 119 *pcbRead = 0; 120 120 if (rc > 0) 121 rc = -__libc_ native2errno(rc);121 rc = -__libc_back_native2errno(rc); 122 122 LIBCLOG_ERROR_RETURN_INT(rc); 123 123 } … … 170 170 *pcbWritten = 0; 171 171 if (rc > 0) 172 rc = -__libc_ native2errno(rc);172 rc = -__libc_back_native2errno(rc); 173 173 LIBCLOG_ERROR_RETURN_INT(rc); 174 174 } … … 219 219 LIBCLOG_RETURN_INT(0); 220 220 } 221 rc = -__libc_ native2errno(rc);221 rc = -__libc_back_native2errno(rc); 222 222 LIBCLOG_ERROR_RETURN_INT(rc); 223 223 } … … 391 391 FS_RESTORE(); 392 392 if (rc > 0) 393 rc = -__libc_native2errno(rc); 394 LIBCLOG_ERROR_RETURN_INT(rc); 395 } 396 397 398 /** Duplicate handle operation. 399 * @returns 0 on success. 400 * @returns Negated errno on failure. 401 * @param pFH Pointer to the handle structure to operate on. 402 * @param pfhNew Where to store the duplicate filehandle. 403 * The input value describe how the handle is to be 404 * duplicated. If it's -1 a new handle is allocated. 405 * Any other value will result in that value to be 406 * used as handle. Any existing handle with that 407 * value will be closed. 408 */ 393 rc = -__libc_back_native2errno(rc); 394 LIBCLOG_ERROR_RETURN_INT(rc); 395 } 396 397 398 /** @copydoc __LIBC_FHOPS::pfnSync */ 399 static int fhOS2FileSync(__LIBC_PFH pFH) 400 { 401 LIBCLOG_ENTER("pFH=%p:{.fh=%d}\n", (void *)pFH, pFH->fh); 402 FS_VAR_SAVE_LOAD(); 403 404 int rc = DosResetBuffer(pFH->fh); 405 FS_RESTORE(); 406 if (__predict_true(!rc)) 407 LIBCLOG_RETURN_INT(0); 408 rc = -__libc_back_native2errno(rc); 409 LIBCLOG_ERROR_RETURN_INT(rc); 410 } 411 412 413 /** @copydoc __LIBC_FHOPS::pfnDuplicate */ 409 414 static int fhOs2FileDuplicate(__LIBC_PFH pFH, int *pfhNew) 410 415 { 411 return -ENOSYS; 416 LIBCLOG_ENTER("pFH=%p:{.fh=%d} pfhNew=%p:{%d}\n", (void *)pFH, pFH->fh, (void *)pfhNew, *pfhNew); 417 FS_VAR_SAVE_LOAD(); 418 419 HFILE hNew; 420 int rc; 421 if (*pfhNew < 0) 422 { 423 /* new handle */ 424 unsigned cExpandRetries = 0; 425 for (;;) 426 { 427 hNew = ~0; 428 rc = DosDupHandle(pFH->fh, &hNew); 429 if (rc != ERROR_TOO_MANY_OPEN_FILES) 430 break; 431 if (cExpandRetries++ >= 3) 432 break; 433 /* autoincrement. */ 434 __libc_FHMoreHandles(); 435 } /* ... retry 3 times ... */ 436 } 437 else 438 { 439 /* specific handle */ 440 hNew = *pfhNew; 441 rc = DosDupHandle(pFH->fh, &hNew); 442 } 443 if (!rc) 444 { 445 __LIBC_PFH pFHNew; 446 rc = __libc_FHAllocate(sizeof(__LIBC_FH), &__libc_back_gFileOps, hNew, hNew, pFH->fFlags, &pFHNew); 447 if (!rc) 448 { 449 pFHNew->fFlags = pFH->fFlags; 450 pFHNew->iLookAhead = pFH->iLookAhead; 451 pFHNew->Inode = pFH->Inode; 452 pFHNew->Dev = pFH->Dev; 453 pFHNew->pFsInfo = __libc_back_fsInfoObjAddRef(pFH->pFsInfo); 454 pFHNew->pszNativePath = _hstrdup(pFH->pszNativePath); 455 456 /* 457 * OS/2 does, as SuS specifies, clear the noinherit flag. So, we update 458 * the flags of the new handle and in strict mode call __libc_FHSetFlags 459 * to invoke the out of sync check in there. 460 */ 461 pFHNew->fFlags &= ~((FD_CLOEXEC << __LIBC_FH_FDFLAGS_SHIFT) | O_NOINHERIT); 462 LIBC_ASSERT(!__libc_FHSetFlags(pFHNew, pFHNew->fFlags)); 463 464 /* set the return value */ 465 *pfhNew = hNew; 466 FS_RESTORE(); 467 LIBCLOG_RETURN_MSG(0, "ret 0 - *pfhNew=%d\n", *pfhNew); 468 } 469 else 470 DosClose(hNew); 471 } 472 else 473 rc = -__libc_back_native2errno(rc); 474 LIBCLOG_ERROR_RETURN_INT(rc); 412 475 } 413 476 … … 465 528 466 529 /** Operations on sockets. */ 467 static const __LIBC_FHOPS gSocketOps =530 const __LIBC_FHOPS gOS2FileOps = 468 531 { 469 532 enmFH_File, /* Handle type. */ … … 473 536 fhOs2FileSeek, 474 537 fhOS2FileSizeSet, 538 fhOS2FileSync, 475 539 fhOs2FileDuplicate, 476 540 fhOs2FileFileControl, -
trunk/libc/src/libc/io/Makefile.kmk
r2918 r2920 73 73 $(PATH_LIBC_SRC)/libc/io/fsetpos.c \ 74 74 $(PATH_LIBC_SRC)/libc/io/fstat.c \ 75 $(PATH_LIBC_SRC)/libc/io/fsync.c \ 75 76 $(PATH_LIBC_SRC)/libc/io/ftell.c \ 76 77 $(PATH_LIBC_SRC)/libc/io/ftruncat.c \ … … 126 127 $(PATH_LIBC_SRC)/libc/io/ttyname.c \ 127 128 $(PATH_LIBC_SRC)/libc/io/ttyname_r.c \ 129 $(PATH_LIBC_SRC)/libc/io/umask.c \ 128 130 $(PATH_LIBC_SRC)/libc/io/ungetc.c \ 129 131 $(PATH_LIBC_SRC)/libc/io/unlink.c \ -
trunk/libc/src/libc/io/dup.c
r871 r2920 1 /* dup.c (emx+gcc) -- Copyright (c) 1992-1996 by Eberhard Mattes 2 -- Copyright (c) 2003 by Knut St. Osmunden */ 1 /* $Id: $ */ 2 /** @file 3 * 4 * kLIBC - dup(). 5 * 6 * Copyright (c) 2006 knut st. osmundsen <bird-srcspam@anduin.net> 7 * 8 * 9 * This file is part of kLIBC. 10 * 11 * kLIBC is free software; you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License as published 13 * by the Free Software Foundation; either version 2 of the License, or 14 * (at your option) any later version. 15 * 16 * kLIBC is distributed in the hope that it will be useful, 17 * but WITHOUT ANY WARRANTY; without even the implied warranty of 18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 19 * GNU Lesser General Public License for more details. 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * along with kLIBC; if not, write to the Free Software 23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 24 * 25 */ 3 26 4 27 #include "libc-alias.h" 28 #include <unistd.h> 5 29 #include <io.h> 6 #include <emx/syscalls.h> 30 #include <errno.h> 31 #include <klibc/backend.h> 32 #define __LIBC_LOG_GROUP __LIBC_LOG_GRP_IO 33 #include <klibc/logstrict.h> 7 34 8 35 int _STD(dup)(int fh) 9 36 { 10 return __dup(fh); 37 LIBCLOG_ENTER("fh=%d\n", fh); 38 39 int fhNew = -1; 40 int rc = __libc_Back_ioDuplicate(fh, &fhNew, 0 /* no closing */); 41 if (!rc) 42 LIBCLOG_RETURN_INT(fhNew); 43 44 errno = -rc; 45 LIBCLOG_ERROR_RETURN_INT(-1); 11 46 } 47 -
trunk/libc/src/libc/io/dup2.c
r871 r2920 1 /* dup2.c (emx+gcc) -- Copyright (c) 1992-1996 by Eberhard Mattes 2 -- Copyright (c) 2003 by Knut St. Osmunden */ 1 /* $Id: $ */ 2 /** @file 3 * 4 * kLIBC - dup(). 5 * 6 * Copyright (c) 2006 knut st. osmundsen <bird-srcspam@anduin.net> 7 * 8 * 9 * This file is part of kLIBC. 10 * 11 * kLIBC is free software; you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License as published 13 * by the Free Software Foundation; either version 2 of the License, or 14 * (at your option) any later version. 15 * 16 * kLIBC is distributed in the hope that it will be useful, 17 * but WITHOUT ANY WARRANTY; without even the implied warranty of 18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 19 * GNU Lesser General Public License for more details. 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * along with kLIBC; if not, write to the Free Software 23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 24 * 25 */ 3 26 4 27 #include "libc-alias.h" 28 #include <unistd.h> 5 29 #include <io.h> 6 #include <emx/syscalls.h> 30 #include <errno.h> 31 #include <klibc/backend.h> 32 #define __LIBC_LOG_GROUP __LIBC_LOG_GRP_IO 33 #include <klibc/logstrict.h> 7 34 8 int _STD(dup2)(int handle1, int handle2)35 int _STD(dup2)(int fh, int fhNew) 9 36 { 10 /* TODO: Block signals */ 11 if (__dup2(handle1, handle2) < 0) 12 return -1; 13 return handle2; 37 LIBCLOG_ENTER("fh=%d fhNew=%d\n", fh, fhNew); 38 int rc; 39 40 if (fhNew >= 0) 41 { 42 rc = __libc_Back_ioDuplicate(fh, &fhNew, 1 /* close */); 43 if (!rc) 44 LIBCLOG_RETURN_INT(fhNew); 45 } 46 else 47 rc = -EBADF; 48 errno = -rc; 49 LIBCLOG_ERROR_RETURN_INT(-1); 14 50 } 51 -
trunk/libc/src/libc/io/pipe.c
r2739 r2920 1 /* pipe.c (emx+gcc) -- Copyright (c) 1992-1996 by Eberhard Mattes */ 1 /* $Id: $ */ 2 /** @file 3 * 4 * kLIBC - pipe(). 5 * 6 * Copyright (c) 2006 knut st. osmundsen <bird-srcspam@anduin.net> 7 * 8 * 9 * This file is part of kLIBC. 10 * 11 * kLIBC is free software; you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License as published 13 * by the Free Software Foundation; either version 2 of the License, or 14 * (at your option) any later version. 15 * 16 * kLIBC is distributed in the hope that it will be useful, 17 * but WITHOUT ANY WARRANTY; without even the implied warranty of 18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 19 * GNU Lesser General Public License for more details. 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * along with kLIBC; if not, write to the Free Software 23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 24 * 25 */ 2 26 3 27 #include "libc-alias.h" 28 #include <unistd.h> 4 29 #include <io.h> 5 #include <fcntl.h>6 30 #include <errno.h> 7 #include <klibc/io.h> 8 #include <emx/syscalls.h> 31 #include <klibc/backend.h> 32 #define __LIBC_LOG_GROUP __LIBC_LOG_GRP_IO 33 #include <klibc/logstrict.h> 9 34 10 35 extern int _fmode_bin; 11 36 12 /** The default pipe size. */ 13 int _pipe_size; 37 int _STD(pipe)(int *paFHs) 38 { 39 LIBCLOG_ENTER("paFHs=%p\n", (void *)paFHs); 14 40 15 int _STD(pipe)(int *two_handles) 16 { 17 __LIBC_PFH pFHRead, pFHWrite; 41 int fhRead; 42 int fhWrite; 43 int rc = __libc_Back_ioPipe(&fhRead, &fhWrite, 0 /* default size */, !!_fmode_bin); 44 if (!rc) 45 { 46 paFHs[0] = fhRead; 47 paFHs[1] = fhWrite; 48 LIBCLOG_RETURN_MSG(0, "ret 0 - paFH=%p:{%d,%d}\n", (void *)paFHs, paFHs[0], paFHs[1]); 49 } 18 50 19 if (__pipe(two_handles, _pipe_size != 0 ? _pipe_size : 8192, &pFHRead, &pFHWrite) != 0) 20 return -1; 51 errno = -rc; 52 LIBCLOG_ERROR_RETURN_INT(-1); 53 } 21 54 22 /** @todo move _fmode_bin check to __pipe()? */23 if (!_fmode_bin)24 {25 pFHRead->fFlags |= O_TEXT;26 pFHWrite->fFlags |= O_TEXT;27 }28 __libc_FHPut(pFHRead);29 __libc_FHPut(pFHWrite);30 31 return 0;32 }
Note:
See TracChangeset
for help on using the changeset viewer.