Deleted Added
full compact
32c32
< * $Id: uthread_writev.c,v 1.7 1998/05/27 00:44:58 jb Exp $
---
> * $Id: uthread_writev.c,v 1.8 1998/06/09 23:21:05 jb Exp $
50a51
> int type;
73a75,85
> /* Get the read/write mode type: */
> type = _thread_fd_table[fd]->flags & O_ACCMODE;
>
> /* Check if the file is not open for write: */
> if (type != O_WRONLY && type != O_RDWR) {
> /* File is not open for write: */
> errno = EBADF;
> _FD_UNLOCK(fd, FD_WRITE);
> return (-1);
> }
>