diff options
| author | welch <welch> | 1998-08-06 11:40:25 (GMT) | 
|---|---|---|
| committer | welch <welch> | 1998-08-06 11:40:25 (GMT) | 
| commit | 0ef093b2cfc0e47dc470c6ad263653ee564c4d72 (patch) | |
| tree | c95b0583f3a1ce5c818d5382542628e6145f0eb2 /unix/tclUnixChan.c | |
| parent | ffbaca9a6f6b29a18875738d3ffc3239adc9a844 (diff) | |
| download | tcl-0ef093b2cfc0e47dc470c6ad263653ee564c4d72.zip tcl-0ef093b2cfc0e47dc470c6ad263653ee564c4d72.tar.gz tcl-0ef093b2cfc0e47dc470c6ad263653ee564c4d72.tar.bz2  | |
Nuked EINTR wrappers
Diffstat (limited to 'unix/tclUnixChan.c')
| -rw-r--r-- | unix/tclUnixChan.c | 100 | 
1 files changed, 0 insertions, 100 deletions
diff --git a/unix/tclUnixChan.c b/unix/tclUnixChan.c index b846169..28e62e5 100644 --- a/unix/tclUnixChan.c +++ b/unix/tclUnixChan.c @@ -2571,103 +2571,3 @@ TclUnixWaitForFile(fd, mask, timeout)      }      return result;  } - -/* - *---------------------------------------------------------------------- - * - * TclOpen, etc. -- - * - *	Below are a bunch of procedures that are used by Tcl instead - *	of system calls.  Each of the procedures executes the - *	corresponding system call and retries automatically - *	if the system call was interrupted by a signal. - * - * Results: - *	Whatever the system call would normally return. - * - * Side effects: - *	Whatever the system call would normally do. - * - * NOTE: - *	This should be the last page of this file, since it undefines - *	the macros that redirect read etc. to the procedures below. - * - *---------------------------------------------------------------------- - */ - -#undef open -int -TclOpen(path, oflag, mode) -    char *path; -    int oflag; -    int mode; -{ -    int result; -    while (1) { -	result = open(path, oflag, (mode_t)mode); -	if ((result != -1) || (errno != EINTR)) { -	    return result; -	} -    } -} - -#undef read -int -TclRead(fd, buf, numBytes) -    int fd; -    VOID *buf; -    size_t numBytes; -{ -    int result; -    while (1) { -	result = read(fd, buf, (size_t) numBytes); -	if ((result != -1) || (errno != EINTR)) { -	    return result; -	} -    } -} - -#undef waitpid -extern pid_t waitpid _ANSI_ARGS_((pid_t pid, int *stat_loc, int options)); - -/* - * Note:  the #ifdef below is needed to avoid compiler errors on systems - * that have ANSI compilers and also define pid_t to be short.  The - * problem is a complex one having to do with argument type promotion. - */ - -#ifdef _USING_PROTOTYPES_ -int -TclWaitpid _ANSI_ARGS_((pid_t pid, int *statPtr, int options)) -#else -int -TclWaitpid(pid, statPtr, options) -    pid_t pid; -    int *statPtr; -    int options; -#endif /* _USING_PROTOTYPES_ */ -{ -    int result; -    while (1) { -	result = (int) waitpid((pid_t) pid, statPtr, options); -	if ((result != -1) || (errno != EINTR)) { -	    return result; -	} -    } -} - -#undef write -int -TclWrite(fd, buf, numBytes) -    int fd; -    VOID *buf; -    size_t numBytes; -{ -    int result; -    while (1) { -	result = write(fd, buf, (size_t) numBytes); -	if ((result != -1) || (errno != EINTR)) { -	    return result; -	} -    } -}  | 
